O
O
olegan_092018-04-22 01:18:27
macOS
olegan_09, 2018-04-22 01:18:27

Error installing npm i packages on mac and gulp, how to fix?

Can't install npm packages on mac, gulp won't install either. Node is the latest version, so is npm. When you type sudo npm i or npm i gives the following errors:
npm WARN saveError ENOENT: no such file or directory, open '/Users/mac/package.json'
npm WARN enoent ENOENT: no such file or directory, open '/Users /mac/package.json'
npm WARN mac No description
npm WARN mac No repository field.
npm WARN mac No README data
npm WARN mac No license field.
When installing gulp (sudo npm install -g gulp) the error trace is
npm WARN deprecated [email protected]: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util -ca3b1f9f9ac5
npm WARN deprecated [email protected]: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js
npm WARN deprecated [email protected]: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated [email protected]: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated [email protected]: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js
npm WARN deprecated [email protected]: This module relies on Node.js's internals and will break at some point. Do not use it, and update to [email protected]
/usr/local/bin/gulp -> /usr/local/lib/node_modules/gulp/bin/gulp.js
+ [email protected]
updated 1 package in 8.278s
Tell me how to fix?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
M
Michael, 2018-04-22
@mak_ufo

You can't install packages locally because there is no package.json in the folder where npm is called from i
Global packages are installed normally. WARN is a warning, not an error.
PS Next time, post console screenshots or upload logs to pastebin. So readable

O
olegan_09, 2018-04-22
@olegan_09

the same errors were when updating NPM with the command: sudo npm i npm.
Then everything got up with the command: sudo npm install npm -g
But this does not help when installing packages

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question