Created
January 16, 2015 17:40
-
-
Save smathy/012214f6b10aa9d741d1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
09:39:14 ~/work/r4.2.0 $ rails c | |
Loading development environment (Rails 4.2.0) | |
[1] pry(main)> f = Foo.first | |
Foo Load (0.3ms) SELECT "foos".* FROM "foos" ORDER BY "foos"."id" ASC LIMIT 1 | |
=> #<Foo:0x007fa18bf146c0 id: 1, name: "Jason", age: 44, created_at: Wed, 07 Jan 2015 01:52:26 UTC +00:00, updated_at: Wed, 07 Jan 2015 01:59:01 UTC +00:00> | |
[2] pry(main)> show-source f.wee | |
From: /Users/jk/work/r4.2.0/app/models/foo.rb @ line 7: | |
Owner: Foo | |
Visibility: public | |
Number of lines: 3 | |
def wee | |
return 0 | |
end | |
[3] pry(main)> f.wee | |
=> 0 | |
[4] pry(main)> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment