Installing RubyGems in Cygwin
This is as much a reminder for myself as anything else – as I’ve now had to do this about a dozen times between repaving my laptop, home workstation, and work machine(s).
The How-To
Don't try to install RubyGems for Cygwin using the gem that comes with the Ruby One-Click Installer for Windows. Instead, get the tarball, or zip file, and install it using the included installer script.Since RubyGems is pure Ruby you don't have to worry about having a compiler installed. It should just work with the default Cygwin install plus Ruby and its dependencies. To install it, do the following steps:
- Download the RubyGems tarball from Ruby Forge
- Unpack the tarball
- In a bash terminal, navigate to the unpacked directory
- Run the following command:
ruby setup.rb install
- Update RubyGems by running the following:
gem update --system
Note: You may need to run the updated command twice if you have any previously installed gems.
I had to freshly install Compass and Susy today. I did not have a problem using the Ruby Gems Version that comes with Cygwin if you install Ruby via setup.exe. Everything worked.
ReplyDeleteNow if this holds true, it would save us all quite some work, and nice work by the Cygwin team.
Although this is an old post, it helped me a lot today, thank you for taking the time to write it.
ReplyDelete