javascript - no command 'gulp' found - after installation -


after installing gulp.js via npm receive no command 'gulp' found error when running gulp command same directory installed into.

when looking under node_modules/.bin/ directory can see gulp executable there.

is there wrong npm installation?

that's normal. if want gulp-cli available on command line, need install globally.

npm install --global gulp-cli 

see the install instruction.

also, node_modules/.bin/ isn't in $path. automatically added npm when running npm scripts (see this blog post reference).

so add scripts package.json file:

{     "name": "your-app",     "version": "0.0.1",     "scripts": {         "gulp": "gulp",         "minify": "gulp minify"     } } 

you run npm run gulp or npm run minify launch gulp tasks.


Comments

Popular posts from this blog

c# - How to get the current UAC mode -

postgresql - Lazarus + Postgres: incomplete startup packet -

javascript - Ajax jqXHR.status==0 fix error -