Make Sure You Have Ruby

To see whether you already have Ruby on your system, open a console window. If you're a Unix user, this will generally be something like an xterm window. If you're a Windows user, look in the Start menu for the MS-DOS prompt.

Now type ruby -v and press Return.

						% ruby
						-v
ruby 1.7.0 (2001-04-02) [i586-linux]

If the response is a Ruby version number and a creation date (not necessarily matching those shown here), we can move forward. If not, visit http://www.ruby-lang.org to download the right Ruby for your system. Installation instructions will come with whatever package you get, but if you need more help, refer to Appendix B of this book.

Get Sams Teach Yourself Ruby in 21 Days now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.