Public Gists by lachlanhardy

Gravatar
Thu Nov 26 04:16:31 -0800 2009
1
2
3
/* This is a small patch to make callbacks work - I'll con Mr Speaker
into getting some proper scm on this sucker soon */
 
Gravatar
Sun Nov 15 20:35:55 -0800 2009
1
2
3
unicorn -p 4567
/usr/local/lib/ruby/gems/1.8/gems/unicorn-0.95.0/lib/unicorn_http.bundle: Failed to load /usr/local/lib/ruby/gems/1.8/gems/unicorn-0.95.0/lib/unicorn_http.bundle (LoadError)
from /usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require'
Gravatar
Wed Oct 21 22:51:07 -0700 2009
1
2
3
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
Gravatar
Wed Jul 08 23:09:48 -0700 2009
1
2
3
# cut out of a real app, so a bit bastardised and probably wouldn't run as it's own Sinatra app, but I think it pretty much covers the entire process of Twitter OAuth
 
require 'sinatra'
Gravatar
Tue May 12 07:08:29 -0700 2009
1
2
3
# assume we're passing the values from the file below as arguments to the following:
# WTF is name always nil?
 
Gravatar
Sat May 02 02:46:53 -0700 2009
1
2
3
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang='en-US' xml:lang='en-US' xmlns='http://www.w3.org/1999/xhtml'>
  <head>
Gravatar
Mon Mar 09 20:14:57 -0700 2009
1
2
3
# So this is in my controller:
 
@items = Dir.glob("views/*/*")
Gravatar
Sun Mar 08 22:40:42 -0700 2009
1
2
3
  %p
    Please confirm the upgrade from
    %strong= Plan[session[:old_plan_id]]
Gravatar
Wed Mar 04 19:37:10 -0800 2009
1
2
3
              - if @category == name
                %a.selected{:href => name}
                  %span= name
Gravatar
Wed Feb 25 19:10:09 -0800 2009
1
2
3
def f(ra,n)
  r=0
  ra.each {|x| r+=1 if x.include? n}
gist: 4061 Twitterific Power User sett...
Gravatar
Tue Aug 05 05:06:27 -0700 2008
1
privatefilter.bash