This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Copyright (c) 2014, Mike 'Fuzzy' Partin <[email protected]> | |
All rights reserved. | |
Redistribution and use in source and binary forms, with or without | |
modification, are permitted provided that the following conditions are met: | |
1. Redistributions of source code must retain the above copyright notice, this | |
list of conditions and the following disclaimer. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# On the Chromebook: | |
# | |
DEV=/dev/mmcblk1 | |
MNT=/mnt | |
# Unmount from wherever ChromeOS decided to mount the device, | |
# remount where we want: | |
umount ${DEV}p2 | |
mount ${DEV}p2 ${MNT} | |
# Complete the bootstrap: | |
chroot ${MNT} /debootstrap/debootstrap --second-stage |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[255, 0, 0] | |
[255, 0, 0] | |
[255, 87, 0] | |
[255, 196, 0] | |
[205, 255, 0] | |
[ 95, 255, 0] | |
[ 0, 255, 13] | |
[ 0, 255, 122] | |
[255, 0, 0] | |
[255, 96, 0] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import re | |
import json | |
import shlex | |
import types | |
import ConfigParser | |
_tokens = [] | |
data = {'global': {}} | |
regex = { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
"reflect" | |
) | |
type ApiKey struct { | |
Key string | |
Enabled bool |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
"reflect" | |
) | |
type ApiKey struct { | |
Key string | |
Enabled bool |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
// "bufio" | |
// "io" | |
"fmt" | |
"os" | |
"math" | |
"path" | |
"math/rand" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
unset GOROOT | |
unset GOPATH | |
GOBASE=${HOME}/.govers/$(uname -s)/$(uname -m) | |
GO_SVER=${1:-"1.4.2"} | |
go14src=https://storage.googleapis.com/golang/go${GO_SVER}.src.tar.gz | |
go14fnm=$(basename ${go14src}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
go14src=https://storage.googleapis.com/golang/go1.4.2.src.tar.gz | |
go14fnm=$(basename ${go14src}) | |
bootstrap() { | |
cd /tmp | |
wget ${go14src} | |
tar zxf ${go14fnm} | |
cd /tmp/go/src |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
must() { | |
case "${1}" in | |
(have) | |
case "${2}" in | |
(file) test -f ${3} || err "Missing file: ${3}" ;; | |
(link) test -L ${3} || err "Missing symlink: ${3}" ;; | |
(dir) test -d ${3} || err "Missing dir: ${3}" ;; | |
(prog) which ${3} >/dev/null 2>&1 || err "Missing ${2}: ${3}" ;; | |
(user) test ! -z "$(grep ${3} /etc/passwd)" || err "Missing ${2}: ${3}" ;; | |
(group) test ! -z "$(grep ${3} /etc/group)" || err "Missing ${2}: ${3}" ;; |