Skip to content

Instantly share code, notes, and snippets.

View chilts's full-sized avatar

Andrew Chilton chilts

View GitHub Profile
@chilts
chilts / gist:687ec1e8c5337213a7e1a5de2d3584ae
Last active March 28, 2019 14:51
Dump a BoltDB (zipped) to a Dir with a Timestamp
package main
// From : https://gist.github.com/chilts/687ec1e8c5337213a7e1a5de2d3584ae
import (
"compress/gzip"
"fmt"
"log"
"os"
"path"
@chilts
chilts / handlers.go
Last active March 8, 2017 04:40
Simple, re-usable handlers for standard tasks.
package main
// https://gist.github.com/chilts/db1adfaddaae871b161d7eadab6b1278
import (
"bytes"
"html/template"
"log"
"net/http"
)
@chilts
chilts / ReadMe.md
Last active October 18, 2016 21:03
"How Dropbox securely stores your passwords" in terrible, insecure, horrible GoLang (GoLang is not terrible, my code is).
@chilts
chilts / dump.go
Created September 15, 2016 19:53
Dump entire BoltDB to stdout, including Nested Buckets
package main
import (
"fmt"
"log"
"strings"
"time"
"github.com/boltdb/bolt"
)
@chilts
chilts / out.txt
Created September 22, 2015 11:57
./make.all
chilts@ant:~/go/src$ time env GO_TEST_TIMEOUT_SCALE=10 GOROOT_BOOTSTRAP=$HOME/go-linux-arm-bootstrap ./all.bash
##### Building Go bootstrap tool.
cmd/dist
##### Building Go toolchain using /home/chilts/go-linux-arm-bootstrap.
bootstrap/internal/obj
bootstrap/asm/internal/flags
bootstrap/compile/internal/big
bootstrap/internal/gcprog
bootstrap/internal/obj/arm
@chilts
chilts / json-verify
Last active September 2, 2015 10:25
My Release Procedures
#!/usr/bin/env node
// core
var fs = require('fs');
try {
var json = fs.readFileSync(process.argv[2]).toString('utf8');
} catch (e) {
console.log('json-verify: ' + e);
process.exit(2);
$ node client.js
--- signUp ---
{
"uid": "8bc2add5218d4f10971a139a54ad6a4f",
"sessionToken": "00b4e46c5e94fdec7726ea1bc145363ba8174c8794d470134b6bf1f1364ce5d6",
"authAt": 1427337145
}
prompt: code: fdfe175d9f20fa0d3e1d8e7a61dfa481
--- verifyCode ---
{}
@chilts
chilts / housekeeping.txt
Created September 17, 2014 21:33
Housekeeping
Each repo:
* README.md
* package.json
* description
* repository
* author
* license
* homepage
* bugs
-----BEGIN PGP MESSAGE-----
Version: GnuPG v1.4.11 (GNU/Linux)
hQEMA1m/rf1rAzwlAQf+IYlOAq4XOQy2dl8BkBWv3/Pa8kB0r2vpOf2eOZ7pzVK8
qWWTOPRetBFqmfsJJlx5q4Y2VA/FOazZZCYi2/2hB/tLRBziLN3t88hpgbYKjuOr
neir4jBbCkfQ8fqCa7gO+x3juQvjhVILLecIPsbNf/hzsiRCIajvI1YirncrkfIT
5z+ZDcntKsCOTgN76HHN0mG9XnvKLGEqQUp1klVb9HarsEd1VMtk5v/YO3Y+9qqh
zQWt3LdieyPDBuhHud0nH9AVOvS71+jf7htKghYB1Tq40VYJVZsc47i8FqAvTuVL
RazWermyYm1LjMsTWzWrkSGOfYfiPNxxVWt+v4BMe9J4AUIDuajXVn0KPWfxp1go
FT6OwliVCktx2qFO+3GpvpnTHUcjP0uQa/nVx1SUHXfLwWLV415dt61RL1RYzA59
@chilts
chilts / keybase.md
Created March 26, 2014 03:48
Keybase Proof

Keybase proof

I hereby claim:

  • I am chilts on github.
  • I am chilts (https://keybase.io/chilts) on keybase.
  • I have a public key whose fingerprint is 233F 80A4 462A B14B AB46 9504 B382 E549 5685 997E

To claim this, I am signing this object: