1

sudo gem install sass

ERROR: While executing gem ... (Gem::FilePermissionError) You don't have write permissions for the /usr/bin directory.

therefore not working grunt watch

grunt watch Running "watch" task Waiting...

File "scss/modules/_base.scss" changed. Running "sass:dist" (sass) task /Library/Ruby/Site/2.3.0/rubygems.rb:289:in find_spec_for_exe': can't find gem sass (>= 0.a) with executable sass (Gem::GemNotFoundException) from /Library/Ruby/Site/2.3.0/rubygems.rb:263:inbin_path' from /usr/local/bin/sass:22:in `' Warning: Exited with error code 1 Use --force to continue.

Aborted due to warnings. Completed in 1.020s at Tue Dec 04 2018 05:00:37 GMT-0800 (Pacific Standard Time) - Waiting...

  • Does this answer your question? [Grunt sass don't have ruby and sass installed?](https://stackoverflow.com/questions/24269242/grunt-sass-dont-have-ruby-and-sass-installed) – Silviu Burcea May 20 '20 at 12:55

3 Answers3

2

Have you installed the xcode dev tools yet? Try this first:

xcode-select --install

And then install Sass:

sudo gem install sass
keyboard-warrior
  • 324
  • 2
  • 11
1

May for only install it, you can use -n option: sudo gem install -n /usr/local/bin sass

But,i strongly recommends you to use a ruby manager, like RVM (https://rvm.io/rvm/install) supports MacOS, permits you to have multiple Ruby versions and keep all your gems organized by version.

Dimitrius Lachi
  • 1,277
  • 2
  • 9
  • 21
0

I was getting the exact same error.

For me running sudo npm install -g sass resolved the issue.

Shivani
  • 33
  • 6