Grunt - bundler:无法加载命令:scss-lint

时间:2016-09-27 16:42:05

标签: ruby twitter-bootstrap gruntjs rubygems

我在本地设置了bootstrap 4,当我运行grunt watch时,我收到以下警告:

Running "scsslint:docs" (scsslint) task
Warning: 
bundleExec options set but no Bundler executable found in your PATH.
More info: https://github.com/ahmednuaman/grunt-scss-lint
 Use --force to continue.

Aborted due to warnings. 

为了解决这个问题,我运行了以下命令:

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

然后我收到以下消息:

Running "scsslint:docs" (scsslint) task
Running scss-lint on docs
>> 1. Please make sure you have ruby installed: `ruby -v`
>> 2. Install the `scss-lint` gem by running:
>> gem update --system && gem install scss-lint

所以我运行了以下命令:

sudo gem update --system -n /usr/local/bin
sudo gem install scss_lint -n /usr/local/bin

现在,当我运行grunt watch时,我得到以下内容:

Running "scsslint:docs" (scsslint) task
Running scss-lint on docs
bundler: failed to load command: scss-lint (/usr/local/bin/scss-lint)
Warning: Task "scsslint:docs" failed. Use --force to continue.

我在OSX El Capitan。任何人都知道如何解决这个问题?

仅供参考我必须在命令上使用-n / usr / local / bin参数,因为它会给我

1 个答案:

答案 0 :(得分:0)

不确定是什么问题,但scss-lint基本上是语法检查程序。我发现如果我删除了TWBS符合的scss-lint

尝试:

sudo gem uninstall scss-lint

希望会有比这更好的答案,但是现在这将让你前进。