Created
October 4, 2012 10:08
-
-
Save swarut/3832705 to your computer and use it in GitHub Desktop.
Rails : Setting up hirb #rails #hirb
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
require 'hirb' | |
require 'pry' | |
ActiveSupport.on_load :active_record do | |
Hirb::Formatter.dynamic_config['ActiveRecord::Base'] | |
Hirb.enable | |
old_print = Pry.config.print | |
Pry.config.print = proc do |output, value| | |
Hirb::View.view_or_page_output(value) || old_print.call(output, value) | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment