sajad torkamani

Instead of opening up the Ruby Docs in a web page like this, we can use the ri (Ruby Index) command-line tool to quickly lookup the documentation for a Ruby method, class, or module.

ri # View docs for method
ri File # View docs for class
ri Enumerable # View docs for module

Ruby is a very rich language with lots of built-in methods so being able to quickly look up the docs for its various methods saves a lot of time.

ri should be installed automatically when you install Ruby itself.

Tagged: Ruby

Leave a comment

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