Skip to content

Instantly share code, notes, and snippets.

doing codes

Daniel Compton dan-compton

doing codes
Block or report user

Report or block dan-compton

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:c1b8d5ed441efa64b8bf
//used something like this in a disclosure to regarding bruteforcing
package main
import (
dan-compton / exponentialbackoff.go
Created Feb 22, 2016
Exponential backoff that takes a clojure
View exponentialbackoff.go
// something like
type clj func() (interface{}, error)
func DoWithBackoff(retries int, fn clj) (interface{}, error) {
for try := 0; try < retries; try++ {
output, err := fn()
if err != nil || try < 6 { // Todo(you) remove || try < 6
log.WithError(err).Error("Failed to execute.")
} else {
import collections
import pprint
import operator
d = collections.defaultdict(int)
z = {}
print 'total chars:',len(original)
for c in original:
dan-compton / gist:9f6e3b4a09f1caf2c44d
Created Oct 10, 2015
Bruteforce saucey promocodes
View gist:9f6e3b4a09f1caf2c44d
package main
import (
log ""

Keybase proof

I hereby claim:

  • I am dan-compton on github.
  • I am dacompton ( on keybase.
  • I have a public key whose fingerprint is 7F77 DA08 DBE5 A809 C90C AA47 445D 96F2 B57A FB74

To claim this, I am signing this object:

dan-compton / timestamp.go
Created Oct 5, 2015 — forked from bsphere/timestamp.go
UNIX timestamps in Golang
View timestamp.go
package timestamp
import (
type Timestamp time.Time
dan-compton / terminator-config
Last active Aug 29, 2015 — forked from jacaetevha/terminator-config
save this file to ~/.config/terminator
View terminator-config
enabled_plugins = CustomCommandsMenu, InactivityWatch, TestPlugin, ActivityWatch, TerminalShot, LaunchpadCodeURLHandler, APTURLHandler, MavenPluginURLHandler, LaunchpadBugURLHandler, LayoutManager
title_transmit_bg_color = "#832527"
dan-compton /
Last active Aug 29, 2015
Bash script to set up my development environment in Ubuntu64
mkdir ~/.provision
cd ~/.provision
sudo apt-get install vim
sudo apt-get install git
sudo apt-get install terminator
echo "installing source code pro..."
git clone git:// ~/.vim_runtime
sh ~/.vim_runtime/
brew install ctags
echo "set nu" >> ~/.vimrc
echo "set paste" >> ~/.vimrc
echo "set color vim-irblack" >> ~/.vimrc
echo "set guifont=Source\ Code\ Pro\ 14" >> ~/.vimrc
echo ".vimrc set nu, set paste, set color vim-irblack"
echo "installing terminator config"
You can’t perform that action at this time.