Forum: Ruby on Rails ./script/console - disabling "records found.inspect"?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
429500a5a54600958c9c7ac032a37f66?d=identicon&s=25 Joe (Guest)
on 2006-04-05 04:48
How do I disable console's default behavior of automatically outputting
what appears to be an inspect of all records found? For example:

>> Item.find(:all).each do |item|
>>   puts item.title
>> end
# bunch of text outputted that shows the contents of all fields in all
items...

Joe
Ef3aa7f7e577ea8cd620462724ddf73b?d=identicon&s=25 Rob Biedenharn (Guest)
on 2006-04-07 03:03
(Received via mailing list)
Item.find(:all).each do |item|
   puts item.title
end ; nil

Really!
Well, you do have to put up with the:
=> nil
But I find that acceptable ;-)

-Rob


Rob Biedenharn		http://agileconsultingllc.com
Rob@AgileConsultingLLC.com
+1 513-295-4739
This topic is locked and can not be replied to.