We installed Ruby for Windows from RubyInstaller (for Windows). We installed Ruby 1.8.7-p180 and its associated documentation. The documentation is in p7zip format – so you might need 7zipfor windows to open up the documentation. Download a 7Zip installer here. I allowed the windows installer for windows to place the Ruby binaries and helper files into it default location (c:\Ruby187).

Since Aptana (which will will use for Rails development) is touchy about changing Ruby versions this is a better option than placing Ruby in a generic location like C:\Ruby. To use Ruby scripts or interactively you will need to have ruby on your path. In my case the path value needs to include c:\Ruby187\bin. Note that this is the executable path for Ruby and irb (interactive Ruby) and not the load path (aka $Load_Path). I put the path into my local user environment set. As you develop your Ruby chops you can write short Ruby programs in the text editor of your choice, save them with an extension of “rb” and then run them from a command shell as: For quick learning experiences there is also a Ruby line interpreter (irb). Run it as:

Ruby.exe (and irb) can be run with an assortment of command line options. Find out about these by running: Ruby –h and irb –h. There are several ways to install support libraries to Ruby. The most common method is to use Ruby GEMS. GEMS support is pre-loaded with Ruby 1.8.7 and can be accessed through the command shell and (as usual) minimal help can be found using the –h command line option. So there you have it for command line Ruby. A Ruby compiler and Why’s (poignant) Guide To Ruby is all you need to get started. In my next installment to this series we will move on to a Ruby IDE – specifically the Aptana RadRails (and Ruby) IDE.