🍖Rib A lightweight and extensible irb replacement

Lightweight comparing to alternatives

Less codes, launches faster

rib irb pry
Lines of code 1500 4500 9000
Launch time (ms) 377.5 867.2 891.3
Data on 2017-01-25

Easy extensible

Use built-in plugins or write your own

Here's a small list of some more special built-in plugins:
  • Multiline history
  • Bottom up backtrace
  • In-place editing
  • Auto-indention
  • Output pagination

Less complex

Therefore less likely to have bugs

Utilize Ruby's parser directly instead of a separate parser like irb, therefore less likely to evaluate differently. For example, evaluating {if: 42} in irb was broken once (issue)

gem install rib


Start the shell by running rib If you need Rails console, then run rib rails If you need Rack console, then run rib rack You could also run rib auto for detecting application.


Try with rib all to enable almost all built-in plugins for above example.

rib -h

Usage: rib [ruby OPTIONS] [rib OPTIONS] [rib COMMANDS]
ruby options:
  -e, --eval LINE        Evaluate a LINE of code
  -d, --debug            Set debugging flags (set $DEBUG to true)
  -w, --warn             Turn warnings on (set $-w and $VERBOSE to true)
  -I, --include PATH     Specify $LOAD_PATH (may be used more than once)
  -r, --require LIBRARY  Require the library, before executing your script
rib options:
  -c, --config FILE      Load config from FILE
  -p, --prefix PATH      Prefix to locate the app. Default to .
  -n, --no-config        Suppress loading any config
  -h, --help             Print this message
  -v, --version          Print the version
rib commands:
  all                    Load all recommended plugins
  auto                   Run as Rails or Rack console (auto-detect)
  min                    Run the minimum essence
  rack                   Run as Rack console
  rails                  Run as Rails console


Rib started in 2011 and has been maintained since then. It aims to be lightweight and extensible so it could work for anyone. It's minimal in its core, but it still offers a lot more features such as debugging, in-place editing and more via built-in plugins. Check out README for more details.