Thin and fast
rib | irb | pry | |
---|---|---|---|
Lines of code | 1500 | 4500 | 9000 |
Launch time (ms) | 404.4 | 404.6 | 624.4 |
Data on 2018-05-22 |
Use built-in plugins or write your own
Therefore less likely to have bugs
Utilize Ruby's parser directly instead of a separate parser like irb, therefore less likely to behave differently. For example, evaluating {if: 42}
in irb was once broken (issue)
gem install rib
Start the shell by:
rib
Pure ruby consolerib rails
Rails consolerib rack
Rack consolerib auto
for auto detecting application
rib all
to enable almost all built-in plugins for above example.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.