Skip to content

Instantly share code, notes, and snippets.

@roopeshvaddepally
Forked from loginx/.irbrc
Created June 24, 2011 04:50
Show Gist options
  • Save roopeshvaddepally/1044250 to your computer and use it in GitHub Desktop.
Save roopeshvaddepally/1044250 to your computer and use it in GitHub Desktop.
~/.irbrc config file to enable ActiveRecord logging to the rails console (if in rails console) and enable IRB autocompletion and autoindent.
require 'irb/completion'
require 'pp'
IRB.conf[:AUTO_INDENT]=true
if defined?(Rails) && !Rails.env.nil?
ActiveRecord::Base.logger = Logger.new(STDOUT)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment