Skip to content
Browse files

Output other logs (deprecation warnings, etc) in pry.

  • Loading branch information...
1 parent a9e6203 commit 81286664af4fd17687138d981a7deee844342350 @jasoncodes committed Feb 8, 2012
Showing with 4 additions and 1 deletion.
  1. +4 −1 pryrc
View
5 pryrc
@@ -50,8 +50,11 @@ Pry.hooks.add_hook :before_session, :rails do |output, target, pry|
ActiveRecord::Base.logger = Logger.new STDOUT
end
- # load Rails console commands
if defined?(Rails) && Rails.env
+ # output all other log info such as deprecation warnings to the console
+ Rails.logger = Logger.new STDOUT
+
+ # load Rails console commands
if Rails::VERSION::MAJOR >= 3
require 'rails/console/app'
require 'rails/console/helpers'

0 comments on commit 8128666

Please sign in to comment.
Something went wrong with that request. Please try again.