Skip to content

Instantly share code, notes, and snippets.

View bitjson's full-sized avatar

Jason Dreyzehner bitjson

View GitHub Profile
find . -type f -name '*.php' -exec awk 'END {print NR}' '{}' + 2>/dev/null | awk '{ total+=$1 }END{print total}'
bitjson /
Last active August 29, 2015 14:02

Keybase proof

I hereby claim:

  • I am bitjson on github.
  • I am jasondreyzehner ( on keybase.
  • I have a public key whose fingerprint is 308F 3EAD EB11 CF09 06A1 F2AB 412D 8152 9D88 6082

To claim this, I am signing this object:

bitjson / gist:211231ec070f4e4137f5
Created August 20, 2014 21:05 Verification
Verifying that +jasondreyzehner is my Bitcoin username. You can send me #bitcoin here:
bitjson / pwn.json
Created September 2, 2014 16:47
"A" : "4",
"B" : "Ƀ",
"C" : "C",
"D" : "D",
"E" : "3",
"F" : "F",
"G" : "G",
"H" : "H",
"I" : "1",
bitjson /
Last active December 4, 2017 16:29
Setting up on a Mac


Hard Drive Encryption

Encrypt your hard drive by activating FileVault in System Preferences > Security & Privacy. A recovery key will be generated which will allow access to your encrypted hard drive in the case of a forgotten password. Store this key securely (do not select the option to store your key with Apple).

Dev Environment

ruby -e "$(curl -fsSL"
bitjson / bst.schema.json
Created December 5, 2018 20:46 — forked from jcramer/bst.schema.json
Bitcoin Script Template (BST) Schema
"description": "Definition file for Bitcoin Script Templates",
"$schema": "",
"$id": "",
"title": "Bitcoin Script Template (BST) JSON Schema",
"type": "object",
"properties": {
"description": "BST schema version",
"type": "integer",
bitjson /
Last active October 26, 2023 20:31
Example Gist for Importing into Bitauth IDE
bitjson /
Last active September 28, 2023 13:53
CashChannels: Recurring Payments for Bitcoin Cash
bitjson / example.ts
Created February 10, 2020 17:58
CashAddress Encoding, Decoding, and Error Correction in Javascript
import { instantiateSecp256k1, hexToBin, instantiateRipemd160, encodeCashAddress, CashAddressType, instantiateSha256, encodeCashAddressFormat, attemptCashAddressFormatErrorCorrection, decodeCashAddress, decodeCashAddressFormat, stringify } from 'bitcoin-ts';
(async () => {
const secp256k1 = await instantiateSecp256k1();
const sha256 = await instantiateSha256();
const ripemd160 = await instantiateRipemd160();
// Create an address from a private key
const privateKey = hexToBin('f85d4bd8a03ca106c9deb47b791803dac7f0333809e3f1dd04d182e0aba6e553');
const publicKey = secp256k1.derivePublicKeyCompressed(privateKey);
bitjson /
Last active February 2, 2024 06:30
PMv3-Based CashTokens (Withdrawn)