Category Archives: Uncategorized

Install Compass & SASS on Windows 7

On your Windows environment, you’ll need to install Ruby via the installer: http://rubyinstaller.org/about/contributors/ after running the setup open the commandline: (Windows run > type: CMD, the latest version of ruby installer 1.9.3 has a command prompt in the installation folder in program files)
Check if ruby is installed, navigate to the Ruby bin folder, and type:
ruby -v
$ gem install haml
$ gem install haml-edge
$ gem install compass

To install SASS  & Compass on Windows 7, is not that hard, however because I was in a corporate environment, I had to set my HOMEDIR Environment variable so that it would work correctly.

When I Tried to install Compass with:

$ gem install compass

I would get the error:  ERROR: While executing gem … (Errno::ENOENT)
I checked the environment variables by running:

$ gem env

But this did not really help.

After some searching I found this link:  Troubleshoot Gem which explains the problem.

Cause:

  • If HOME environment variable is not set, Ruby tries to use a combination of HOMEDRIVE and HOMEPATH (e.g. the unaccessible network drive) and fails.

Workaround:

  • On the command line, execute “SET HOME=%USERPROFILE%”, which will tell Ruby to use your user profile directory (C:\Users\xyz) as the home directory.