Skip to content

Instantly share code, notes, and snippets.

View brandy's full-sized avatar
🍑
Chillin

Brandon brandy

🍑
Chillin
View GitHub Profile
@brandy
brandy / download.js
Created November 26, 2022 23:51 — forked from falkolab/download.js
Download file by http with progress (NodeJS)
function download(fileUrl, apiPath, callback) {
var url = require('url'),
http = require('http'),
p = url.parse(fileUrl),
timeout = 10000;
var file = fs.createWriteStream(apiPath);
var timeout_wrapper = function( req ) {
return function() {
@sebsto
sebsto / gist:6af5bf3acaf25c00dd938c3bbe722cc1
Last active February 27, 2024 14:01
Start VNCServer on Mac1 EC2 Instance
# YouTube (english) : https://www.youtube.com/watch?v=FtU2_bBfSgM
# YouTube (french) : https://www.youtube.com/watch?v=VjnaVBnERDU
#
# On your laptop, connect to the Mac instance with SSH (similar to Linux instances)
#
ssh -i <your private key.pem> ec2-user@<your public ip address>
#
# On the Mac
@ashrafmajdee
ashrafmajdee / FootIK
Created May 7, 2020 13:48 — forked from Orixe/FootIK
Free Foot IK system for unity
using UnityEngine;
[RequireComponent(typeof(Animator))]
public class FootIK : MonoBehaviour
{
[Header("Main")]
[Range(0, 1)] public float Weight = 1f;
[Header("Settings")]
public float MaxStep = 0.5f;
public float FootRadius = 0.15f;
@Orixe
Orixe / FootIK
Last active December 17, 2023 15:22
Free Foot IK system for unity
using UnityEngine;
[RequireComponent(typeof(Animator))]
public class FootIK : MonoBehaviour
{
[Header("Main")]
[Range(0, 1)] public float Weight = 1f;
[Header("Settings")]
public float MaxStep = 0.5f;
public float FootRadius = 0.15f;
@Otienoh
Otienoh / ubuntu-server-setup-16.04-LAMP.md
Last active January 4, 2022 04:53
LAMP Server setup for Ubuntu 16.04 on Digital Ocean

Server setup for Ubuntu 16.04 on Digital Ocean

The setup installs the following software:

The setup installs the following software:

  • Apache
  • MySQL
  • PHP
  • Node
@JeffreyWay
JeffreyWay / countries.php
Created July 23, 2015 17:01
Country Names + Codes
[
"United States" => "us",
"Afghanistan" => "af",
"Albania" => "al",
"Algeria" => "dz",
"American Samoa" => "as",
"Andorra" => "ad",
"Angola" => "ad",
"Anguilla" => "ai",
"Antarctica" => "aq",
@falkolab
falkolab / download.js
Created July 30, 2014 08:16
Download file by http with progress (NodeJS)
function download(fileUrl, apiPath, callback) {
var url = require('url'),
http = require('http'),
p = url.parse(fileUrl),
timeout = 10000;
var file = fs.createWriteStream(apiPath);
var timeout_wrapper = function( req ) {
return function() {
@marknotfound
marknotfound / Remove Gmail Image Proxy
Created February 5, 2014 20:16
A bookmarklet to remove Gmail's image proxy links so you can load locally hosted images in your Gmail inbox during email tests.
javascript:(function(){var e=new RegExp("^https://[a-zA-Z0-9]+.googleusercontent.com/proxy/[a-zA-Z0-9_-]+[=][a-zA-Z0-9-+]+#");var t=document.getElementsByTagName("img");for(var n=0;n<t.length;n++){t[n].src=t[n].src.replace(e,"")}})()
@plentz
plentz / nginx.conf
Last active April 24, 2024 11:15
Best nginx configuration for improved security(and performance)
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048
@luetkemj
luetkemj / wp-query-ref.php
Last active April 25, 2024 09:37
WP: Query $args
// This gist is now maintained on github at https://github.com/luetkemj/wp-query-ref
<?php
/**
* WordPress Query Comprehensive Reference
* Compiled by luetkemj - luetkemj.github.io
*
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query#Parameters
* Source: https://core.trac.wordpress.org/browser/tags/4.9.4/src/wp-includes/query.php
*/