Skip to content

Instantly share code, notes, and snippets.

View lenary's full-sized avatar

Sam Elliott lenary

View GitHub Profile
# Sample localization file for English. Add more files in this directory for other locales.
# See http://github.com/svenfuchs/rails-i18n/tree/master/rails%2Flocale for starting points.
en:
admin_page:
welcome: "A stained blog is a nice blog!"
statistics: "There {{is_or_are_counter}} currently {{visible_posts}} with {{visible_comments}} and {{hidden_comments}}. Also you have {{users}}, while there are {{guests}}"
ago: "ago"
approve: "Approve"
@lenary
lenary / .aliases
Created February 18, 2010 10:45 — forked from jlong/.aliases
# Console
alias profile="vi ~/.bash_profile"
alias ls="ls -p -G -h"
# Desktop Programs
alias fireworks="open -a '/Applications/Adobe Fireworks CS3/Adobe Fireworks CS3.app'"
alias photoshop="open -a '/Applications/Adobe Photoshop CS4/Adobe Photoshop.app'"
alias illustrator="open -a '/Applications/Adobe Illustrator CS4/Adobe Illustrator.app'"
alias preview="open -a '/Applications/Preview.app'"
alias xcode="open -a '/Developer/Applications/Xcode.app'"
def new
# supply the default values to the new form.
# no params are getting posted to this so no need to look in params[]
@comment = Comment.new(default_attributes)
end
def create
# first step, make a new comment with the stuff posted to your action, but with the default attributes
#
# hash_a.merge(hash_b) gets every element of hash_b to override elements with the same key in hash_a,
These tickets can be closed. I have tested them personally and they either seem to be fixed or don't apply anymore.
https://rails.lighthouseapp.com/projects/8994/tickets/3631
https://rails.lighthouseapp.com/projects/8994/tickets/3501 [fixed]
--------------------------------
| RESOLVED TICKETS |
--------------------------------
https://rails.lighthouseapp.com/projects/8994/tickets/3038
require 'sinatra'
module Sinatra
module Foo
module Helpers
def foo
@bar = 'Bye'
end
end
def self.registered(app)
@lenary
lenary / blog.rb
Created May 19, 2009 20:07 — forked from vangberg/blog.rb
require 'sinatra'
class Blog < Sinatra::Default
get '/' do
..
end
end
if __FILE__ == $0
Blog.run!
end