Public Gists by webmat

Gravatar
Fri Oct 02 07:12:28 -0700 2009
1
2
3
# Neater Github gem dependencies for Rails
 
module GithubGem
Gravatar
Wed Jul 15 13:22:14 -0700 2009
1
2
3
# In .irbrc
# then when you want to play with generating urls from the console,
# just call make_urls and you're set.
Gravatar
Tue May 26 06:17:49 -0700 2009
1
2
3
# Our deployment tags are s or p followed by YYmmdd-HHMMSS
namespace :deploy do
  namespace :pending do
Gravatar
Thu Dec 04 15:12:06 -0800 2008
1
2
3
class String
  # Return everything after the given string
  # or nil if the substring can't be found
Gravatar
Fri Nov 21 12:42:20 -0800 2008
1
2
3
# Rubygems 1.3.1 incompatible with rbx. Missing constant EACCESS
 
# Either with the dev's bin/ in the path or rbx symlinked in the path,
Gravatar
Fri Nov 21 12:10:32 -0800 2008
1
2
3
# IRB prompt that looks like code samples
IRB.conf[:USE_READLINE] = true
IRB.conf[:AUTO_INDENT] = false
Gravatar
Thu Nov 20 11:48:05 -0800 2008
1
2
3
#console
sudo gem install ruby_parser
 
Gravatar
Mon Nov 17 21:13:58 -0800 2008
1
2
3
#!/usr/bin/env ruby
 
# Filename: mdc
Gravatar
Sun Oct 26 22:20:15 -0700 2008
1
2
3
# For the queasy, this is MIT licensed. See comment at the end.
 
module ExceptionMacros
Gravatar
Tue Oct 21 10:59:20 -0700 2008
1
2
3
membership_of_favourite_club:
  joined_on: <%= 3.weeks.ago.to_s(:db) %>
  club: moustache_club
Gravatar
Fri Oct 10 06:28:37 -0700 2008
1
2
3
#!/usr/bin/env ruby
 
# An improved GitHub gemspec checker.
gist: 15920 Check out the values of all...
Gravatar
Thu Oct 09 15:15:52 -0700 2008
1
2
3
# Check out the values of all instance variables in object 'o':
 
o.instance_variables.inject({}) {|memo,v|