My Recent Pastes (540 and counting)
Pastes by rsl (540 and counting)
Below are the 15 most recent pasties by rsl.
September 16, 2008
6:57PM EDT
by rsl
View all 68 lines
class Klass @array = [1,2,3] def self.fuckup backup = @array.dup
September 16, 2008
5:12PM EDT
by rsl
View all 23 lines
> class Foo def speak puts "speaking" end end
September 15, 2008
2:24PM EDT
by rsl
View all 11 lines
module MyModule def self.included(base) base.extend ClassMethods end
September 11, 2008
2:09PM EDT
by rsl
View all 48 lines
From d3eedfaae09942c3d99377174ddf8cd554eee0a2 Mon Sep 17 00:00:00 2001 From: rsl <rsl@luckysneaks.com> Date: Thu, 11 Sep 2008 14:07:44 -0400 Subject: [PATCH] don't hit the db if there's no ids for records
September 10, 2008
2:24PM EDT
by rsl
View all 79 lines
From 9b1480a62af1c7a9141bbd3f74cf50098144e3fa Mon Sep 17 00:00:00 2001 From: rsl <rsl@luckysneaks.com> Date: Wed, 10 Sep 2008 14:22:05 -0400 Subject: [PATCH] fixed association preloading to use = instead of IN when there's only one record
September 09, 2008
12:28AM EDT
by rsl
View all 39 lines
sneaky:optimized_oyster rsl$ sudo gem cleanup Cleaning up installed gems... Attempting to uninstall capistrano-2.4.3 Successfully uninstalled capistrano-2.4.3 Attempting to uninstall capistrano-2.4.0
September 08, 2008
8:47PM EDT
by rsl
View all 54 lines
diff --git a/activerecord/lib/active_record/association_preload.rb b/activerecord/lib/active_record/association_preload.rb index 61fa34a..c60850f 100644 --- a/activerecord/lib/active_record/association_preload.rb +++ b/activerecord/lib/active_record/association_preload.rb @@ -95,7 +95,7 @@ module ActiveRecord
August 15, 2008
2:01PM EDT
by rsl
View all 23 lines
richcollins joined the chat room. [1:49pm] richcollins: Is config.gem completely broken? [1:50pm] richcollins: These gems that this application depends on are missing [1:50pm] richcollins: except they aren't [1:50pm] rsl: richcollins: http://www.codinghorror.com/blog/archives/001079.html
August 15, 2008
12:37PM EDT
by rsl
View all 12 lines
# Override Rails' default def caches_page(*actions) return unless perform_caching actions = actions.map(&:to_s) after_filter do |c|
August 15, 2008
11:25AM EDT
by rsl
scope = Entry.live @entries = params[:time] == "recent" ? scope.recent : scope.all
August 14, 2008
7:19PM EDT
by rsl
View all 24 lines
ignoring attempt to close fund:0x1ffa234 with a
opened at byte 495, line 13
closed at byte 511, line 13
attributes at open: {}
text around open: "href=\"/funds/1352\">#<Fund:0x1ffa234></a>"
August 14, 2008
11:37AM EDT
by rsl
View all 18 lines
def parsed_sort_code @parsed_sort_code ||= sort_code.to_s.scan(/../) end %w{first middle last}.each_with_index do |segment, index|
August 13, 2008
4:13PM EDT
by rsl
View all 6 lines
"> "123asd[,".gsub(/[^[:alnum]]/, "") (irb):1: warning: character class has `[' without escape (irb):1: warning: regexp has `]' without escape # => "123asd[," > "123asd[,".gsub(/[^\[:alnum\]]/, "")
August 13, 2008
3:53PM EDT
by rsl
View all 14 lines
[3:34pm] charsets joined the chat room. [3:35pm] charsets: hey [3:35pm] charsets: if i add [3:35pm] charsets: a new entry in the database [3:35pm] charsets: how do i render it
