Skip to content

Instantly share code, notes, and snippets.

@unixmonkey
unixmonkey / .irbrc
Created December 11, 2009 21:56
.irbrc
require 'pp'
require 'irb/completion'
require 'rubygems'
require 'wirble'
require 'hirb'
Wirble.init
Wirble.colorize
IRB.conf[:AUTO_INDENT]=true
@hugs
hugs / LICENSE
Created February 15, 2010 01:45
The Node.js "Hello World" web server ported to CoffeeScript
I, Jason Huggins, the author of the work "CoffeeScript Web Server" (2010), irrevocably renounce
all current and future legal rights to the work in any medium whatsoever.
I stand behind the merit of the work, but disclaim all liability for it under law.
I encourage you, the audience, to share, copy, distribute, perform, remix, mash up, interpret,
excerpt, translate, and otherwise enjoy and use the work as you will.
I request that you acknowledge my authorship.
@isaacs
isaacs / comma-first-var.js
Created April 6, 2010 19:24
A better coding convention for lists and object literals in JavaScript
// See comments below.
// This code sample and justification brought to you by
// Isaac Z. Schlueter, aka isaacs
// standard style
var a = "ape",
b = "bat",
c = "cat",
d = "dog",
@unixmonkey
unixmonkey / .irbrc
Created April 16, 2010 13:28 — forked from tjh/.irbrc
.irbrc
# *****************************************
# .irbrc
#
# Includes lots of nice stuff to make
# your irb and script/console ruby shell
# more pretty and productive
#
# *****************************************
"""
Script to convert a Xcode3 Color theme into a Xcode4 one.
Example:
bash# python xcode3_theme_to_xcode4.py Twilight.xcolortheme
It will write a new file: Twilight.dvtcolortheme into the same folder as the script is residing in.
"""
import plistlib,sys
""" Define boilerplate of the color theme """
defaultConfig = {
@rkumar
rkumar / itunes.sql
Created August 4, 2010 16:33
itunes music library database
/* create tables to store itunes music library data for quick access
- rkumar 2010 July
*/
drop table tracks;
create table tracks (
album_artist VARCHAR(50),
album_rating_computed INTEGER,
album_rating VARCHAR(50),
album VARCHAR(50),
all_items VARCHAR(50),
@rkumar
rkumar / xml2db.rb
Created August 4, 2010 16:42
convert itunes music library to database sqlite3 using ruby
#!/usr/bin/env ruby
=begin
* Name: xml.rb
* Description parses xml iTunes Music Library and inserts into database
so other apps can use, rather than each time parsing xml file
* Author: Original - Aaron Patterson (xml parsing portion)
http://groups.google.com/group/nokogiri-talk/browse_thread/thread/97973521c6f5f0dc
* Additions by rkumar
* Date: 2010-08-04
* License:
user www www;
worker_processes 5;
error_log logs/error.log;
pid logs/nginx.pid;
worker_rlimit_nofile 8192;
events {
worker_connections 4096;
}
@sanxiyn
sanxiyn / lisp.c
Created August 14, 2010 04:16
Lisp
#include <assert.h>
#include <stdarg.h>
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
enum type {
NIL,
@nkpart
nkpart / article.md
Created September 16, 2010 10:32
Kit - package manager for Objective-C

Packages. Boy, I just don't know.

I'd like to introduce a tool I've written, that I hope will make it easier to share objective-C code across iPhone projects.

The tool is Kit. To install it, you'll need the latest haskell platform release for OS X. Kit installs through haskell's package manager:

$ brew install haskell-platform # If you've got brew, otherwise: http://hackage.haskell.org/platform/mac.html
$ cabal update

$ cabal install kit