How to install your Ruby Rails environment

Before playing with rails, you have some prerequisites. You need the ruby engine, a DevKit to let you compile native extension and the rails gem.

I will show you how to install all of them on windows. It’s a lot easier on Linux ! (apt-get install ruby && gem install rails)

  • Grab the latest installer 32 or 64 bit, install it on C:\Ruby
  • Download the DevKit too, if you don’t have MinGW installed on your computer, take the MinGW included auto extractor 32 or 64 bit. Extract it on C:\DevKit

As said on the DevKit wiki page, you need to type two commands after DevKit download to install it completely.

Open a new command prompt and type:

 

You just installed correctly your Ruby environment. But rails isn’t installed yet. You could install it with a windows installer but it’s much easier by using the gem installer system. Normally you should have the ruby command in your Windows path, this command should work anywhere:

 

You should have rails correctly installed in your path and its command accessible from everywhere.

If not, add manually your Ruby bin directory c:\Ruby200-x64\bin to your PATH

Rails environment installed !

 

If you want to remove by default all doc install with each gem, just type:

For Windows :

 

Leave a Reply

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

Post Navigation