需要使用 gruntjs compass 从 windows 8.1 上的 scss 文件生成 css

need to generate css from scss file on windows 8.1 using gruntjs compass

我正在处理并面临从提供的 tabs.scss 生成 tabs.css 文件的问题。我已经尝试了所有可能的选择。我能够在 dist/ 文件夹下成功生成 tabs.js 但无法生成 tabs.css.

我还有 运行 以下命令:

npm install grunt-contrib-watch --save-dev

npm install --save-dev grunt-sass

npm install grunt-contrib-compass --save-dev

npm install grunt-contrib-cssmin --save-dev

但是当我 运行 > grunt default 时,出现以下错误。

Running "compass:tabs" (compass) task
Warning: Couldn't find the compass.bat binary. Make sure it's installed and in your $PATH Use --force to continue.

Aborted due to warnings.

我正在使用 windows 8.1。

我什至尝试使用在线转换器 http://sassmeister.com/ 将此 tabs.scss 转换为 css。但在这里我收到以下错误:

file to import not found or unreadable: compass/css3/box-sizing

任何人都可以帮助我从 tabs.scss 文件成功生成 tabs.css 吗?

您必须安装 Compass for Windows. Sorry, I am not an expert in Windows, but here is the tutorial 才能做到这一点。

然后确保 compass.bat 在您的 $PATH 中。之后它会编译没有错误。

我也试过编译tabs.scss in sassmeiser.com, but it compiles for me with no error. So i have created a pastie for you: pastie with css