使用gulp-compass编译sass,报错

*Individual stylesheets must be in the sass directory.*

部分关键代码如下

 /* 编译sass文件,然后调用compass进行编译,设置css和sass的路径*/
 gulp.task('compass', function() {
  gulp.src('src/**/*.scss')
    .pipe(compass({
      config_file: './config.rb',
      css: 'src/css',
      sass: 'src/sass'
    }))
    .pipe(gulp.dest('./dist/css/'));
});
require 'compass/import-once/activate'
# Require any additional compass plugins here.

# Set this to the root of your project when deployed:
http_path = "/"
css_dir = "css"
sass_dir = "sass"
images_dir = "images"
javascripts_dir = "javascripts"
"devDependencies": {
    "browser-sync": "^2.8.2",
    "del": "^1.2.1",
    "gulp": "^3.9.0",
    "gulp-compass": "^1.3.3",
    "run-sequence": "^1.1.2"
  }


然后2个小时之后还是觉得自己写的没错,无可奈何,最后还把vscode关闭,重新打开,仍然报错,。。。,就洗洗睡了

早上打开重新执行gulp命令,结果成功了!!!!! **

太气人了!!!!

**

更多推荐

Individual stylesheets must be in the sass directory