IRB Console with history and logging

I spend most time with IRB or Rails/console. These are good settings on which I have settled with over the time. These will allow you to have basic logging and IRB history. Just put these in the ~/.irbrc file (If file doesn’t exist then create one).

Author: Shishir Sharma

Shishir Sharma is a hacker, software developer and a bachelor of electronics & communication engineering. He is a problem solver, technology enthusiast. He can speak in Java, Python, Perl, PHP, Curl etc; Fluent in C, C++, GNU/Linux. He is moderator at LUG-Jaipur. He loves action movies and Counter Strike.

4 thoughts on “IRB Console with history and logging”

  1. On line 17 of the code preview your logic is:

    result = !condition_a && !condition_b

    From boolean algebra,
    a’.b’ = (a + b)’

    Reducing it in terms of boolean algebra, a more correct, and understandable statement could be

    result = ! (condition_a || condition_b)

    The statement would become:
    irb_console_running = (rails_running or script_console_running) ‘

    This is also more intuitive. 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *