0

I am trying to install Gulp globally on a Windows 7 PC. In a command prompt I ran npm install gulp -gand it ran without any errors, although it did return the following warnings:

npm WARN install Couldn't install optional dependency: Failed to parse json
npm WARN install No data, empty input at 1:1
npm WARN install
npm WARN install ^

When I try to run gulp it says it is not recognized as an internal command.

If I check the %AppData%/npm directory, gulp.cmd is not there. Looking at all the answers to gulp command not found - error after installing gulp, I take it this is where it should be.

Any ideas what has gone wrong, or where I can look to see what has gone wrong?

Community
  • 1
  • 1
PRS
  • 667
  • 7
  • 22

1 Answers1

0

When I tried to do a local install of gulp: npm install gulp, it actually showed an error:

Failed to Parse json... File: C:\Users\username|AppData\Roaming\npm-cache\clone\1.0.2\package\package.json

When I deleted this file and retried the Global install, it then worked.

PRS
  • 667
  • 7
  • 22