My Recent Pastes (218 and counting)
Pastes by lifo (218 and counting)
Below are the 15 most recent pasties by lifo.
September 23, 2008
6:54AM EDT
by lifo
View all 29 lines
<h1><%= :novy_clanok.l %> </h1> <% form_tag :action => 'create' do %>
September 20, 2008
8:27AM EDT
by lifo
#!/usr/bin/env ruby require File.dirname(__FILE__) + '/config/environment' require 'rack' options = {:Port => 9292, :Host => "0.0.0.0", :AccessLog => []} Rack::Handler::Mongrel.run ActionController::Dispatcher.new, options
September 19, 2008
11:07AM EDT
by lifo
View all 6 lines
[15:22] lifo: make an app [15:22] lifo: where you enter a url [15:22] lifo: and the app tells u how environment friendly it is [15:23] bakineggs: wtf does that mean? [15:24] lifo: idk
September 17, 2008
6:40PM EDT
by lifo
View all 34 lines
def gc_statistics(description = "", options = {}) #do nothing if we don't have patched Ruby GC yield and return unless GC.respond_to? :enable_stats GC.enable_stats || GC.clear_stats
September 16, 2008
6:30PM EDT
by lifo
View all 29 lines
require 'rubygems' require 'activerecord' ActiveRecord::Base.establish_connection :adapter => "mysql", :host => "localhost", :username => "root", :database => "property_db" ActiveRecord::Base.logger = Logger.new($stdout)
September 16, 2008
6:11PM EDT
by lifo
View all 38 lines
require 'rubygems' require 'ostruct' require 'activerecord' ActiveRecord::Base.establish_connection :adapter => "sqlite3", :database => "property.db"
September 16, 2008
10:45AM EDT
by lifo
View all 22 lines
class Array def call(method) each {|e| send(method, e)} end
September 16, 2008
10:18AM EDT
by lifo
View all 8 lines
class Array def call(method) each {|e| send(method, e)} end end
August 28, 2008
10:34AM EDT
by lifo
View all 402 lines
diff --git a/actionpack/lib/action_controller/base.rb b/actionpack/lib/action_controller/base.rb index 55e1d48..2d173ad 100644 --- a/actionpack/lib/action_controller/base.rb +++ b/actionpack/lib/action_controller/base.rb @@ -331,6 +331,14 @@ module ActionController #:nodoc:
April 22, 2008
7:25PM EDT
by lifo
View all 9 lines
## application.rb class Application helper :whatever
April 16, 2008
12:33PM EDT
by lifo
View all 16 lines
require "ruby-prof" ActionView::TemplateFinder.process_view_paths(path) view = ActionView::Base.new(path)
April 03, 2008
3:48PM EDT
by lifo
View all 19 lines
Last login: Thu Apr 3 21:35:30 on ttys001 null:~ lifo$ rails -v Rails 2.0.2 null:~ lifo$ sudo gem uninstall rails Password:
March 26, 2008
10:25AM EDT
by lifo
View all 8 lines
1) Failure: test_native_types(MigrationTest) [./test/cases/migration_test.rb:361:in `test_native_types' ./test/cases/../../lib/../../activesupport/lib/active_support/testing/setup_and_teardown.rb:59:in `__send__'
March 22, 2008
5:44PM EDT
by lifo
View all 6 lines
validates_each(attr_names,configuration) do |record, attr_name, value| condition_sql = "#{record.class.quoted_table_name}.#{attr_name} #{attribute_condition(value)}" condition_params = [value] if scope = configuration[:scope]
