Improve PRY and IRB Ruby Console Output

José Ney Guerrero
DAK42
Published in
1 min readJan 30, 2019

The default output of PRY or IRB isn’t the most legible experience, there’s a way to improve it using a gem.

The gem is https://github.com/awesome-print/awesome_print here’s how to configure it, although this are the same instructions in the readme of the repo.

To use it in IRB, first create the file .irbrc in your ~ home directory, then add this code:

require “awesome_print”
AwesomePrint.irb!

To use it in PRY, first create the file .pryrc in your ~ home directory, then add this code:

require "awesome_print"
AwesomePrint.pry!

Both solutions work when using the rails console too 🙏

--

--