Active::Record Logger to STDOUT with pry
Put this in your ~/.pryrc file and you're good to go:
Pry.config.hooks.add_hook(:before_session, :rails) do
if defined?(Rails)
ActiveRecord::Base.logger = Logger.new(STDOUT)
end
end
Written by Benjamin Knofe
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Ruby
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#