Skip to content

Instantly share code, notes, and snippets.


Nate Murray jashmenn

View GitHub Profile
View tbr90-red-flag.js
const fs = require("fs");
const CoinGecko = require("coingecko-api");
const { table } = require("table");
const chalk = require("chalk");
const cg = new CoinGecko();
const coins = [
{ "id": "ethereum", "symbol": "ETH" },
{ "id": "bitcoin", "symbol": "BTC" },
jashmenn / Dockerfile
Created January 15, 2021 19:46 — forked from yefim/
Build a Docker image, push it to AWS EC2 Container Registry, then deploy it to AWS Elastic Beanstalk
View Dockerfile
# Example Dockerfile
FROM hello-world
jashmenn / dynamic_forms_builder.sql
Created August 19, 2020 15:48 — forked from firmanelhakim/dynamic_forms_builder.sql
Dynamic Forms Builder using PostgreSQL
View dynamic_forms_builder.sql
CREATE TABLE master.forms
form_id serial NOT NULL,
properties jsonb,
audit_trails jsonb,
sort_order INTEGER,
jashmenn /
Created April 21, 2017 16:16 — forked from katylava/
git selective merge

Example: You have a branch refactor that is quite different from master. You can't merge all of the commits, or even every hunk in any single commit or master will break, but you have made a lot of improvements there that you would like to bring over to master.

Note: This will not preserve the original change authors. Only use if necessary, or if you don't mind losing that information, or if you are only merging your own work.

On master:

> git co -b temp
jashmenn /
Created March 9, 2017 20:21 — forked from piscisaureus/
Checkout github pull requests locally

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 =

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:

View annotation.rb
a = {
"annotations" => [
"x" => 19,
"y" => 20,
"w" => 50,
"h" => 50,
"predictions" => {
"green" => 0.2,
View dumb_graph.js
function sum (fn, xs) {
var toRet = 0;
for (var i = 0, ii = xs.length; i < ii; i++) {
toRet += fn(xs[i], i, xs);
return toRet;
function update(t, o) {
for (var k in o) {
View Protocol.txt
BTCmsg Protocol v1 (2011-09-18)
Each message is represented by multiple payment which is calculated by
the following algorithm:
1. Two first chars for message type ('01' for md5, '02' for ascii).
2. Then the message in hex (python binascii.hexlify).
3. Split the long string to groups of 4 hex digits.
4. Each group of 4 hex (e.g. 2 ascii letters from the message) is
represented by a payment in satoshi (maximum 0xffff=65535).
# Raw transaction API example work-through
# Send coins to a 2-of-3 multisig, then spend them.
# For this example, I'm using these three keypairs (public/private)
# 0491bba2510912a5bd37da1fb5b1673010e43d2c6d812c514e91bfa9f2eb129e1c183329db55bd868e209aac2fbc02cb33d98fe74bf23f0c235d6126b1d8334f86 / 5JaTXbAUmfPYZFRwrYaALK48fN6sFJp4rHqq2QSXs8ucfpE4yQU
# 04865c40293a680cb9c020e7b1e106d8c1916d3cef99aa431a56d253e69256dac09ef122b1a986818a7cb624532f062c1d1f8722084861c5c3291ccffef4ec6874 / 5Jb7fCeh1Wtm4yBBg3q3XbT6B525i17kVhy3vMC9AqfR6FH2qGk
# 048d2455d2403e08708fc1f556002f1b6cd83f992d085097f9974ab08a28838f07896fbab08f39495e15fa6fad6edbfb1e754e35fa1c7844c41f322a1863d46213 / 5JFjmGo5Fww9p8gvx48qBYDJNAzR9pmH5S389axMtDyPT8ddqmw
# First: combine the three keys into a multisig address:
./bitcoind createmultisig 2 '["0491bba2510912a5bd37da1fb5b1673010e43d2c6d812c514e91bfa9f2eb129e1c183329db55bd868e209aac2fbc02cb33d98fe74bf23f0c235d6126b1d8334f86","04865c40293a680cb9c020e7b1e106d8c1916d3cef99aa431a56d253e69256dac09ef122b1a9
jashmenn / dpkg-gnutar
Created December 26, 2011 22:18 — forked from jedi4ever/dpkg-gnutar
homebrew formula to get dpkg working a mac
View dpkg-gnutar
require 'formula'
class Tar <Formula
url ''
homepage ''
md5 '00d1e769c6af702c542cca54b728920d'
# depends_on 'cmake'
def install