Skip to content

Instantly share code, notes, and snippets.

View fuzzy's full-sized avatar

Mike 'Fuzzy' Partin fuzzy

View GitHub Profile
package main
import (
// "bufio"
// "io"
"fmt"
"os"
"math"
"path"
"math/rand"
package main
import (
"fmt"
"reflect"
)
type ApiKey struct {
Key string
Enabled bool
package main
import (
"fmt"
"reflect"
)
type ApiKey struct {
Key string
Enabled bool
@fuzzy
fuzzy / config.py
Last active April 8, 2021 22:19
parses config files
import os
import re
import json
import shlex
import types
import ConfigParser
_tokens = []
data = {'global': {}}
regex = {
@fuzzy
fuzzy / output
Created November 1, 2015 09:56
bull crap output
[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]
# 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
/*
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.
# ./build.sh
npm http GET https://registry.npmjs.org/less
npm http 200 https://registry.npmjs.org/less
npm http GET https://registry.npmjs.org/less/-/less-2.6.0.tgz
npm http 200 https://registry.npmjs.org/less/-/less-2.6.0.tgz
npm http GET https://registry.npmjs.org/errno
npm http GET https://registry.npmjs.org/graceful-fs
npm http GET https://registry.npmjs.org/image-size
npm http GET https://registry.npmjs.org/mime
npm http GET https://registry.npmjs.org/mkdirp
def _argParse(self, args):
if len(args) > 1:
if args[1] not in self.config.arguments.keys():
self.showHelp()
else:
# We really don't need the program name
args.pop(0)
# ok, we have a valid command, now let's see if we
{
"help": {
"help": "Show this help screen.",
"handler": "showHelp"
},
"version": {
"help": "Show the version.",
"handler": "showVersion"
},
"list": {