Skip to content

Instantly share code, notes, and snippets.

View spheromak's full-sized avatar
🕵️‍♂️

Jesse Nelson spheromak

🕵️‍♂️
View GitHub Profile
@eduncan911
eduncan911 / gist:e325fc05b891691999be
Last active March 3, 2016 03:25
Git Pending Repos
# add this code to your .bashrc file
# gitpending() transverses from the current directory to
# inspect 1 directory level deep for any git repos that have
# pending changes to commit.
function gitpending()
{
for d in */ ; do
pushd $d > /dev/null
DIRNAME=$(basename "$d")
@elithrar
elithrar / authserver.go
Last active June 30, 2021 07:12
HTTP Basic Auth example in Go (based on http://stackoverflow.com/a/21937924/556573 + bespoke middleware implementation)
package main
import (
"encoding/base64"
"github.com/gorilla/mux"
"net/http"
"strings"
)
func main() {
@jpetazzo
jpetazzo / README.md
Last active August 21, 2019 17:55
Give network superpowers to docker

Unionize: network superpowers for your docker containers

Unionize lets you connect together docker containers in arbitrarily complex scenarios.

Note: I recommend to use https://github.com/jpetazzo/pipework instead.

  • pipework is a better name than unionize
  • it's hosted on a "real" github repo instead of a small gist :-)

Now if you want Unionize, it's still here. Just check those examples.

@quchen
quchen / trolling_haskell
Last active November 12, 2024 00:10
Trolling #haskell
13:15 <xQuasar> | HASKELL IS FOR FUCKIN FAGGOTS. YOU'RE ALL A BUNCH OF
| FUCKIN PUSSIES
13:15 <xQuasar> | JAVASCRIPT FOR LIFE FAGS
13:16 <luite> | hello
13:16 <ChongLi> | somebody has a mental illness!
13:16 <merijn> | Wow...I suddenly see the error of my ways and feel
| compelled to write Node.js!
13:16 <genisage> | hi
13:16 <luite> | you might be pleased to learn that you can compile
| haskell to javascript now
@acrmp
acrmp / 00_README.md
Created November 10, 2012 00:05
Mocking out a library in Chef

Example of mocking out a library in Chef so you can test the provider in isolation.

If you want to test the library itself you can do more normal Ruby things.

@aaronpk
aaronpk / github-post-receive.rb
Created April 8, 2012 19:53
Automatically configure post-receive hooks on all your Github repositories
require 'json'
require 'uri'
require 'httpclient'
require 'redis'
require 'mw-irc'
# First, get an access token for your account on the command line
# curl -d '{"scopes":["repo"],"note":"Post-Receive Hooks"}' -u 'username:******' https://api.github.com/authorizations
# Paste your access token here
@fnichol
fnichol / README.md
Created February 5, 2012 20:50
Vagrant apt-cacher-ng

Vagrant apt-cacher-ng Box

Simple and easy, just:

mkdir apt-cacher-ng && cd apt-cacher-ng
curl -LO https://raw.github.com/gist/1747868/Vagrantfile
vagrant up

Tail the logs perhaps?

@fujin
fujin / foo.rb
Created January 31, 2012 21:49
template override between cookbooks
template "/tmp/foo.rb"
source "foo.rb.erb"
cookbook "banana"
end
#!/usr/bin/env ruby
require 'benchmark'
require 'optparse'
require 'pp'
require 'rubygems'
require 'yajl'
require 'chef/rest'
module CGrep
class Config