stoeffel / gulp-param

Add params to your tasks
26 stars 8 forks source link

gulp.src is not a function (cli: 2.2.0, local: 4.0.2) #72

Closed Sans84 closed 5 years ago

Sans84 commented 5 years ago
var
    gulp        = require("gulp"),
    livereload  = require("gulp-livereload"),
    sass        = require("gulp-sass"),
    autoprefixer    = require("gulp-autoprefixer");

gulp.task("reload-scss", function() {
    gulp.src('*.scss')
    .pipe(sass().on('error', sass.logError))
    .pipe(autoprefixer({
        browsers: ['last 5 versions'],
        cascade: false,
    }))
    .pipe(gulp.dest('./'))
    .pipe(livereload());
});
[15:13:20] Using gulpfile D:\0\gulpfile.js
[15:13:20] Starting 'default'...
[15:13:29] Starting 'reload-scss'...
[15:13:29] 'reload-scss' errored after 28 ms
[15:13:29] TypeError: gulp.src(...).src is not a function
    at D:\0\gulpfile.js:12:3
    at taskWrapper (D:\0\node_modules\undertaker\lib\set-task.js:13:15)
    at bound (domain.js:402:14)
    at runBound (domain.js:415:12)
    at asyncRunner (D:\0\node_modules\async-done\index.js:55:18)
    at process._tickCallback (internal/process/next_tick.js:61:11)