Skip to content

Installed Gulp CLI but it won't run gulp #96

@no1melman

Description

@no1melman

So I did completely fresh install

npm install gulp-cli

Then created simple gulpfile.js

let gulp = require('gulp');

gulp.task('build', cb => {
    console.log('Building');
    cb();
});

gulp.task('watch', gulp.series('build', cb => {
    console.log('Watching');
    cb();
}));

Then executed

C:\Users____\Documents\Git\trash
λ gulp -v
[23:23:44] CLI version 1.2.2

C:\Users____\Documents\Git\trash
λ gulp watch
[23:23:49] Local gulp not found in ~\Documents\Git\trash
[23:23:49] Try running: npm install gulp

But obviously if I install gulp then it's not going to work because only gulp-cli has series and parallel functions

What is the issue here?


Does it require me to pull down 4.0 branch from gulp???


So I cloned git clone https://github.com/gulpjs/gulp.git --branch 4.0 --single-branch and ran npm install in that gulp directory, then when I did gulp build it worked.

I don't remember having to do this the last time I installed the gulp-cli

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions