Public Gists by defunkt

Gravatar
Sat Nov 21 14:12:10 -0800 2009
1
2
3
$ cat test.rb
class Person
end
gist: 238999 MySQL server has gone away fix
Gravatar
Thu Nov 19 12:00:31 -0800 2009
1
2
3
# If your workers are inactive for a long period of time, they'll lose
# their MySQL connection.
#
Gravatar
Mon Nov 16 11:09:05 -0800 2009
1
2
3
$ ack 'has_many.*:through' | wc -l
       2
$ ack has_and_belongs_to_many | wc -l
Gravatar
Tue Nov 10 14:56:03 -0800 2009
1
2
3
# http://unicorn.bogomips.org/SIGNALS.html
 
namespace :unicorn do
gist: 227361 Reduce your carbon footprint
Gravatar
Thu Nov 05 12:45:43 -0800 2009
1
2
3
### Vim
 
`autocmd BufWritePre * :%s/\s\+$//e`
Gravatar
Wed Nov 04 17:47:37 -0800 2009
1
2
3
$ rvm install 1.9.1 -l 243
 
[2009-11-04 17:46:51] /usr/bin/make
Gravatar
Wed Nov 04 17:34:51 -0800 2009
1
2
3
Persistence
See what's pending
Modify pending jobs in-place
gist: 225369 Resque client in Python
Gravatar
Tue Nov 03 11:49:26 -0800 2009
1
2
3
from redis import Redis
import simplejson
 
Gravatar
Tue Nov 03 11:35:16 -0800 2009
1
2
3
require 'open3'
 
module ShellJob
Gravatar
Mon Oct 26 17:09:49 -0700 2009
1
2
3
$ wget http://gist.github.com/raw/219153/d19a59ba6099580455c57da078b79c5cf801a476/newline.ooc
--2009-10-26 17:09:04-- http://gist.github.com/raw/219153/d19a59ba6099580455c57da078b79c5cf801a476/newline.ooc
Resolving gist.github.com... 207.97.227.243
Gravatar
Mon Oct 26 17:07:45 -0700 2009
1
"hi world" println()
Gravatar
Sat Oct 24 11:31:16 -0700 2009
1
2
3
#!/bin/bash
#
# Save in your .bash_profile then: isreg domain.com
Gravatar
Thu Oct 22 10:46:58 -0700 2009
1
2
3
Vector3f: class {
  x, y, z : Float
 
Gravatar
Thu Oct 22 08:46:43 -0700 2009
1
2
3
require 'rubygems'
require 'bert'
require 'json'
Gravatar
Thu Oct 22 01:30:54 -0700 2009
1
2
3
(gdb) run
Starting program: /Users/chris/Projects/oke/oke
Reading symbols for shared libraries +. done
Gravatar
Thu Oct 22 01:27:55 -0700 2009
1
2
3
/* oke source file, generated with ooc */
#include "oke.h"
 
Gravatar
Thu Oct 22 01:26:37 -0700 2009
1
2
3
Animal: class {
  name: String
  age := 0
Gravatar
Thu Oct 22 00:58:10 -0700 2009
1
2
3
Vector3f: class {
  x, y, z : Float
}
Gravatar
Thu Oct 22 00:53:40 -0700 2009
1
2
3
Document: class {
  data: String
  init: func(=data) {}
Gravatar
Tue Oct 20 19:16:06 -0700 2009
1
$woot->print();