Dirk Dot Net

Creator of useful things. Based in Chiang Mai, Northern Thailand.

Autotest Rails on Windows

If you have trouble getting Autotest to run on Windows with **expand_path': couldn't find HOME environment -- expanding~/.autotest' (ArgumentError) messages and the like,** this post might help you.

So the steps are:

Then "Autotestify" your Rails app by running in the app dir:

>>set home=.

>>autotest -rails

Test away.

Update: If you still get

/site_ruby/1.8/rubygems.rb:385:in latest_partials': undefined method[]' for nil:NilClass (NoMethodError)

or the like, make sure to remove all foreign folders from your gems folder (on Windows, usually C:\ruby\lib\ruby\gems\1.8\gems). Rubygems needs all folders in the - format.

**One more thing: **To get this working with Netbeans 6 (if you still get the couldn't find HOME environment error), you need to create an environment variable named HOME (containing anything), quickest from the command line (if you have the Resource Pack installed with the setx command) for example

setx HOME .

and then restart Netbeans. Autotest will not load before your restart the Netbeans IDE. Hope it helps.

#

lay: thanks a lot!

Francis Fish: To be honest, personally, I'd install Cygwin and run it from an xterminal (after installing the gem etc. in the cygwin install).