Sass can be installed on Mac or Linux using ruby gem. To install sass follow these steps.
- Install sass gem
$ sudo gem install sass
- In case you get the following error
ERROR: While executing gem ... (Errno::EPERM) Operation not permitted - /usr/bin/sass
Then try installing sass in /usr/local/bin
$ sudo gem install -n /usr/local/bin sass
- List sass gem info
$ gem list -d sass *** LOCAL GEMS *** sass (3.4.22) Authors: Natalie Weizenbaum, Chris Eppstein, Hampton Catlin Homepage: http://sass-lang.com/ License: MIT Installed at: /Library/Ruby/Gems/2.0.0 A powerful but elegant CSS compiler that makes CSS fun again.
- Check sass version
$ sass -v Sass 3.4.22 (Selective Steve)
- Display contents in sass package
$ gem contents -l sass