Last active
April 21, 2016 12:48
-
-
Save ahmetabdi/a2f44f21217349f36c5ddcd2e2c9a606 to your computer and use it in GitHub Desktop.
Rails Debugging
This file contains hidden or 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
# Figure out where a method was defined | |
object = Object.new | |
puts object.method(:blank?).source_location | |
=> ["/gems/activesupport-5.0.0.beta1/lib/active_support/core_ext/object/blank.rb", 14] | |
# Opening a dependency from a project | |
$ bundle open active_support | |
# Un-debug a gem | |
gem pristine activesupport | |
# Generate backtrace | |
puts caller | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment