question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Computer doesn't recognize gulp after installation

See original GitHub issue

This tracker is for bug reports only.

Before opening an issue, please make sure you’ve checked the following:

  • For support requests, please use Stack Overflow (stackoverflow.com) or Gitter (see the README).

  • If the bug is in a plugin, open an issue on the plugin repository, not the gulp repository.

  • If you’re getting a deprecated module warning, don’t worry about it: we’re aware of it and it’s not an issue. To make it go away, update to Gulp 4.0.

  • If you’re asking about the status of Gulp 4, please don’t! You can see the remaining issues on the gulp4 label: https://github.com/gulpjs/gulp/issues?q=is%3Aissue+is%3Aopen+label%3Agulp4


What were you expecting to happen? For the command to run my gulp tasks What actually happened? I got an error. gulp command not … So i had to use npx gulp Please post a sample of your gulpfile (preferably reduced to just the bit that’s not working)

gulp.task(function () {});

What version of gulp are you using? 2 i guess What versions of npm and node are you using? Node 10.x Npm 6

Why is this happening is it my computer or npm?

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
sgarciachavezcommented, Jan 17, 2019

I got the same error. I’m on macOS High Sierra version 10.13.6. I installed gulp, uninstalled gulp, re-installed Node.js, npm. Checked all my version:
node -v: v10.15.0 npm -v: 6.41 nps -v: 6.41

Reinstalled gulp: $ sudo npm install --global gulp-cli

/Users/ME/.npm-global/bin/gulp -> /Users/ME/.npm-global/lib/node_modules/gulp-cli/bin/gulp.js

  • gulp-cli@2.0.1 updated 1 package in 6.054s

$ npx mkdirp my-project

npx: installed 2 in 1.768s

$ cd my-project

$ npm init

This utility will walk you through creating a package.json file. It only covers the most common items, and tries to guess sensible defaults.

See npm help json for definitive documentation on these fields and exactly what they do.

Use npm install <pkg> afterwards to install a package and save it as a dependency in the package.json file.

Press ^C at any time to quit. package name: (my-project) my-project version: (1.0.0) 1.0.0 description: Learning Testing entry point: (index.js) index.js test command: npm test git repository: keywords: author: ME license: (ISC) About to write to /Users/ME/my-project/package.json:

{ “name”: “my-project”, “version”: “1.0.0”, “description”: “Learning Testing”, “main”: “index.js”, “scripts”: { “test”: “npm test” }, “author”: “ME”, “license”: “ISC” }

Is this OK? (yes) yes

$ npm install --save-dev gulp

fsevents@1.2.6 install /Users/ME/my-project/node_modules/fsevents node install

node-pre-gyp WARN Using needle for node-pre-gyp https download [fsevents] Success: “/Users/ME/my-project/node_modules/fsevents/lib/binding/Release/node-v64->darwin-x64/fse.node” is installed via remote npm notice created a lockfile as package-lock.json. You should commit this file. npm WARN my-project@1.0.0 No repository field.

  • gulp@4.0.0 added 357 packages from 239 contributors in 8.493s

$ gulp --version

-bash: gulp: command not found

$ npx gulp -v

[10:16:22] CLI version 2.0.1 [10:16:22] Local version 4.0.0

After searching and reading for a day 1/2 I discovered HERE that you need to type “npx” – WHY?

0reactions
ssudarakacommented, Jan 23, 2019

Thanks for the reply. I think the error is with how I configured the path to call npm global modules. I removed everything related to Node, NPM and reinstalled to make it work.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to fix error: "gulp is not recognized as an internal or ...
To install Gulp globally, first make sure you have Node.js installed on your computer. If you don't have it, you can download it...
Read more >
gulp command not found - error after installing gulp
Cmd + R : type "%appdata%" · Go to npm folder · Copy whole path like "C:\Users\Blah...\npm\" · Go to My Computer +...
Read more >
Task Runner Explorer doesn't load Gulp tasks
The workaround would be to change the order of paths in Tools-> Options -> Projects and Solutions -> Web Package Management to make...
Read more >
'gulp' is not recognized as an internal or external command ...
I had similar issue when I installed locally initially(w/o -g). I reinstalled with -g (global) and then it worked. npm install -g gulp....
Read more >
Installing GULP on windows 10
Hi, There doesn't seem to be any documentation on installing/compiling GULP on windows 10. I've tried following the given commands in cmd.exe, however...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found