Skip to content

Instantly share code, notes, and snippets.

(= say
(lambda (something) (puts something)))
(say "anything")
test paste
test paste
curl -F 'repository[name]=API_Hotness' -F 'login=defunkt' -F 'token=6ef8395fecf207165f1a82178ae1b984' http://github.com/repositories
(# examples i used to develop the never-completed Oil)
(# treetop parser is at http://gist.github.com/12454)
(# a simple math class
(= Math (Object.clone
(def square (x) (* x x))
(= square (do (x) (* x x)))
(def abs (x) (
if (>= x 0)
(x)
# Treetop file for the never released Oil
# Oil's spiritual successor is the released Jasper [ http://github.com/defunkt/jasper ]
module Oil
grammar Grammar
rule program
(space expression space)*
end
rule expression
;; gist.el --- Emacs integration for gist.github.com
;; Copyright (C) 2008 Christian Neukirchen <purl.org/net/chneukirchen>
;; Copyright (C) 2008 Chris Wanstrath <chris@ozmm.org>
;; Copyright (C) 2008 Will Farrington <wcfarrington@gmail.com>
;; Licensed under the same terms as Emacs.
;; Version: 0.3.1
;; 26aug2008 +wfarr+
;; 25aug2008 +defunkt+
;; 21jul2008 +chris+
#!/usr/bin/env ruby
=begin
INSTALL:
curl http://github.com/defunkt/gist/tree/master%2Fgist.rb?raw=true > gist &&
chmod 755 gist &&
sudo mv gist /usr/local/bin/gist
@defunkt
defunkt / x
Created October 23, 2008 03:45
CmdUtils.CreateCommand({
name: "page-width",
author: { name: "Jacky See"},
license: "GPL",
description: "Limit the page width by a given parameter, align it to center",
help: "e.g. page-width 400",
takes: {"input": noun_arb_text},
preview: function( pblock, input ) {
var template = "Setting page to width ${w} (default is 500)";
var width = 500; //default width
will this show up?