Rails Development Environment Under Cygwin
Guess what? I like Windows. So sue me.
However DOS sucks, and I need a good CLI. After finding Console I was feeling better, but I still needed the power of *nix command line tools. I usually have a copy of cygwin installed, but I've never dived into it and used it as a development environment.
So I set out to get a functional Rails development environment, and it wasn't too easy, but I made it out alive. Here's what I did in a Nutshell.
Installed Cygwin with
Then you'll need gems, so download the tgz here. Before you install it you'll need to run the following command, else you'll get an error.
$ unset RUBYOPT
After that unzip the gems package and run the setup script.
Then I installed my gems for rails, capistrano, and rails machine.
$ gem install rails --include-dependencies
$ gem install gem_plugin daemons capistrano --include-dependencies
$ gem install mongrel mongrel_cluster railsmachine --include-dependencies
That went smoothly. After that I had a problem where it was using the Windows version of Subversion, instead of the cygwin one. So I changed my PATH in .bash_profile and took out all the windows paths. After that I was able to run cap commands.
Then I needed RMagick, so I had to install ImageMagick first. I re-ran cygwin setup and installed the following packages. I actually didn't install them all at once. It was through a series of trial and error while installing RMagick.
Then install rmagick from the gem.
I figured I might as well keep the windows version of Mysql, but when I ran my tests I could an error saying it couldn't find /tmp/mysql.sock. After some searching I found out that you can fix this by changing 'localhost' to '127.0.0.1' in your config.
Finally, once my tests got to the RMagick stuff, I got some remap error or something. Again to google and I found out that I needed to install 'rebase' and run this command from DOS, with all cygwin instances closed.
> ash rebaseall
That wasn't so bad really. Now I have a fully functional Rails environment running under cygwin!
BTW, I didn't write down the websites that help me along the way, sorry guys.