Friday, March 27, 2009

Ruby "gem" not in Cygwin. Rails not in Cygwin.


gem

Seems odd. It is possible to have the cygwin install include Ruby. Not so gem. So, ya gotta do it manually. There must be a good reason. Cygwin is seriously good stuff. The install is easy.

The idea is to install gem within the cygwin environment. The way to do this is to download a tar() file and run a setup file.

  1. Get the tar() file http://rubyforge.org/frs/?group_id=126
  2. Unwind the tarball "tar xvf ". For me, it was rubygems-1.3.1.tgz
  3. cd() into the directory just created by the tar() operation
  4. Run a ruby script, "ruby setup.rb install"

gem() should now function at the command prompt. Try "type gem", which will display the gem execution path.


rails

Use gem() to install rails

  1. "ruby install rails -include_dependencies"
The -include_dependencies prevents a lot of prompting, and answering "y".

Verify by creating a test app. "rails test"

rake


It is highly likely you will also desire rake.
  1. gem install rake

No comments: