Search code examples
sasscompass-sass

Sass is installed, but command cannot be found


I have a Cpanel-based hosting plan with my provider. I've managed to install both Compass and Sass by using Putty and everything seems to be fine, however when I try to use it I get sass: command not found from the terminal.

I understand that this is probably due to the fact that Sass/Compass are not referred to in environment variables but so far have been unable to find a way to get this to work. I don't have sudo access to the server and have read that I can (maybe) add the PATH manually but I'm not having much luck.


Solution

    1. Make sure you have Ruby & RubyGems installed:

    2. Make sure your GEM_HOME's bin directory is on your path:

      $ echo $PATH | grep $GEM_HOME
      

      2.1. If it isn't, then:

      $ echo "export PATH=$PATH:$GEM_HOME/bin" >> "~/.bash_profile"
      
    3. Install the sass RubyGem package

      gem install sass