我已经从“gulp-compass”:“^ 2.0.3”更新为“gulp-compass”:“^ 2.1.0”现在看起来像gulp-changed给了我一个错误
app/node_modules/gulp-changed/index.js:31
if (sourceFile.stat.mtime > targetStat.mtime) {
^
TypeError: Cannot read property 'mtime' of null
app/node_modules/gulp-changed/index.js:31:23
at Object.oncomplete (fs.js:108:15)
我的gulp任务
gulp.task('sass-desktop', function () {
return gulp.src('scss/*.scss')
.pipe(plumber({
errorHandler: function (error) {
console.log(error.message);
this.emit('end');
}}))
.pipe(compass({
config_file: 'config.rb',
css: 'css',
sass: 'scss',
image: 'images',
debug: false,
require: ['susy', 'modular-scale']
}))
.on('error', function(error) {
// Would like to catch the error here
console.log(error);
this.emit('end');
})
.pipe(autoprefixer({
browsers: ['last 8 versions'],
cascade: false
}))
.pipe(changed('css', {extension: '.css'}))
.pipe(gulp.dest('css'))
});
当有人在gulp-change上打开一个bug时,我添加了一个评论,但看起来这对ruby sass不起作用: https://github.com/sindresorhus/gulp-changed/issues/25#issuecomment-108256528
你知道这个插件的替代品吗?
答案 0 :(得分:0)
答案 1 :(得分:0)