How to resolve “You need to have Ruby and Sass installed and in your PATH for this task to work” Warning?

后端 未结 8 1600
渐次进展
渐次进展 2020-12-07 15:22

I am in the process of setting up a new Mac for work. I have installed Grunt & Grunt CLI globally. Then I did a npm install inside a project folder to insta

相关标签:
8条回答
  • 2020-12-07 15:42

    You need to install Ruby and Sass as:

    For Ruby use command

    sudo apt-get install ruby-full

    And for Sass use command

    sudo gem install sass
    
    0 讨论(0)
  • 2020-12-07 15:52

    I used Homebrew to install Ruby and then Ruby to install SASS. Probably only the best way to do it if you already use Homebrew, or want to start using it regularly...

    brew install ruby
    gem install sass
    
    0 讨论(0)
  • 2020-12-07 15:54

    If you're on OSX El Capitan or Yosemite on Mac there seem to be an issue installing the gem.

    Try

    sudo gem install -n /usr/local/bin sass
    

    Solution was from github.

    0 讨论(0)
  • 2020-12-07 15:57

    Ok I got it. I just had to install Sass using gem install sass and now everything is fine...couldn't be easier.

    0 讨论(0)
  • 2020-12-07 15:58

    Use grunt --force if you are using grunt. If you want to run an application using grunt and a warning is occur like this. For ignoring this warning you can use --force.

    0 讨论(0)
  • 2020-12-07 15:59

    Also simply brew install saas/sass/sass on Mac High Sierra (10.13.x)

    0 讨论(0)
提交回复
热议问题