I am not actively updating this gist and it is already out of date. Please see http://altheamesh.com/documents/universal-payment-channels.pdf
Jehan Tremback
Zackary Hess
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc | |
. ~/.bashrc | |
mkdir ~/local | |
mkdir ~/node-latest-install | |
cd ~/node-latest-install | |
curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1 | |
./configure --prefix=~/local | |
make install # ok, fine, this step probably takes more than 30 seconds... | |
curl https://www.npmjs.org/install.sh | sh |
namespace Analogy | |
{ | |
/// <summary> | |
/// This example shows that a library that needs access to target .NET Standard 1.3 | |
/// can only access APIs available in that .NET Standard. Even though similar the APIs exist on .NET | |
/// Framework 4.5, it implements a version of .NET Standard that isn't compatible with the library. | |
/// </summary>INetCoreApp10 | |
class Example1 | |
{ | |
public void Net45Application(INetFramework45 platform) |
I am not actively updating this gist and it is already out of date. Please see http://altheamesh.com/documents/universal-payment-channels.pdf
Jehan Tremback
Zackary Hess
Promise = require('bluebird') | |
var A = function() { | |
return new Promise(function(resolve, reject) { | |
var result = 'A is done' | |
console.log(result) | |
resolve(result); | |
}) |
// Simple counter | |
type cell = { mutable content : int } | |
let new_counter n = | |
let x :cell = { content = n } | |
fun () -> | |
(x.content <- x.content+1; x.content) | |
// The same, using F# refs | |
let new_counter' n = |
The plan is to create a pair of executables (ngrok
and ngrokd
) that are connected with a self-signed SSL cert. Since the client and server executables are paired, you won't be able to use any other ngrok
to connect to this ngrokd
, and vice versa.
Add two DNS records: one for the base domain and one for the wildcard domain. For example, if your base domain is domain.com
, you'll need a record for that and for *.domain.com
.
ln -s /usr/local/opt/openssl /usr/local/ssl | |
curl -O http://ftp.gnu.org/gnu/wget/wget-1.17.tar.gz | |
tar -xzf wget-1.17.tar.gz | |
cd wget-1.17 | |
./configure --with-ssl=openssl | |
./configure --with-ssl=openssl --with-libssl-prefix=/usr/local/ssl | |
make | |
sudo make install | |
wget --help | |
cd .. && rm -rf wget* |
Locate the section for your github remote in the .git/config
file. It looks like this:
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = [email protected]:joyent/node.git
Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/*
to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:
function doHash(str, seed) { | |
var m = 0x5bd1e995; | |
var r = 24; | |
var h = seed ^ str.length; | |
var length = str.length; | |
var currentIndex = 0; | |
while (length >= 4) { | |
var k = UInt32(str, currentIndex); | |