Skip to content

Instantly share code, notes, and snippets.

View alunny's full-sized avatar

Andrew Lunny alunny

  • Twitter
  • San Francisco, CA
View GitHub Profile

Books

Algorithms and Data Structures

The Art of Computer Programming (Knuth)

Programming Pearls (Bentley)

Data Structures and Algorithms (Aho, Hopcroft, Ullman)

@miketaylr
miketaylr / shebang
Created January 29, 2013 21:03
shebang quine
#!/bin/cat

a Stream spec


##UPDATE

I've now moved this stuff into it's own repo and added an executable checker, and some nifty diagrams of the stream state transitions state diagrams

This gist is no longer being maintained. goto dominictarr/stream-spec


@jed
jed / LICENSE.txt
Created May 16, 2011 18:53 — forked from 140bytes/LICENSE.txt
scope
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Jed Schmidt <http://jed.is>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@mtwstudios
mtwstudios / setup-statsd.sh
Created April 28, 2011 18:30 — forked from jasonroelofs/setup-statsd.sh
Turn a Ubuntu EC2 into a StatsD/Graphite server
# install git
sudo apt-get install g++ curl libssl-dev apache2-utils
sudo apt-get install git-core
# download the Node source, compile and install it
git clone https://github.com/joyent/node.git
cd node
./configure
make
sudo make install
# install the Node package manager for later use
@remy
remy / audiosprite.js
Created December 23, 2010 13:54
An example of how an audio sprite can be used (includes fixes for iOS)
function Track(src, spriteLength, audioLead) {
var track = this,
audio = document.createElement('audio');
audio.src = src;
audio.autobuffer = true;
audio.load();
audio.muted = true; // makes no difference on iOS :(
/* This is the magic. Since we can't preload, and loading requires a user's
input. So we bind a touch event to the body, and fingers crossed, the
@mwbrooks
mwbrooks / kill_bb_simulator.bat
Created August 19, 2010 06:13
BB Simulator wouldn't close on Win7? Kill it!
taskkill /IM fledge.exe
<h1>Demo code for "Extreme JavaScript Performance" @ JSConf.eu</h1>
<script>
var benchmark = function(m,i){
var d1 = new Date, d2, r;
while(i--) r = m();
d2 = new Date;
console.log(d2.getTime()-d1.getTime());
// if(r) console.log(r);
}