sudo npm install -global #angular/cli
npm WARN deprecated request#2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated har-validator#5.1.5: this library is no longer supported
npm ERR! code EEXIST
npm ERR! syscall symlink
npm ERR! path ../lib/node_modules/#angular/cli/bin/ng
npm ERR! dest /usr/bin/ng
npm ERR! errno -17
npm ERR! EEXIST: file already exists, symlink '../lib/node_modules/#angular/cli/bin/ng' -> '/usr/bin/ng'
npm ERR! File exists: /usr/bin/ng
npm ERR! Remove the existing file and try again, or run npm
npm ERR! with --force to overwrite files recklessly.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2020-10-03T08_55_44_693Z-debug.log
I also use Ubuntu 20.04 and I just had the same problem as you.
Here I just updated the npm package (via synaptic).
After this, sudo npm i -g #angular/cli worked ok.
This point solved my problem, maybe that can help you too.
I had a similar problem on Ubuntu 20.04, after I install nodejs (in my case 14.17 stable) and try install Angular.
I went to the directory /usr/bin and deleted the ng file,
after sudo npm i -g #angular/cli.
So ng --version to see if installed ok.
I hope help yo, bye.
Related
When I try to install npm globally, using the command
npm install -g expo-cli
I am getting an error that says
npm install -g expo-cli
npm ERR! code ERR_OSSL_UNSUPPORTED
npm ERR! error:1E08010C:DECODER routines::unsupported
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\user\AppData\Local\npm-cache_logs\2022-04-20T21_10_42_635Z-debug-0.log
Although I just updated my node version to version 17.9.0 and my npm version is 8.5.5.
What can I do to solve this problem?
npx create-react-app shoing eror whent installing, please help me how to solve this
problem. my nodejs version is v16.14.2 and npm version is 8.5.0
Installing packages. This might take a couple of minutes.
Installing react, react-dom, and react-scripts with cra-template...
added 1354 packages in 1m
171 packages are looking for funding
run `npm fund` for details
Initialized a git repository.
Installing template dependencies using npm...
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: instagram-clone#0.1.0
npm ERR! Found: react#18.0.0
npm ERR! node_modules/react
npm ERR! react#"^18.0.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react#"<18.0.0" from #testing-library/react#12.1.5
npm ERR! node_modules/#testing-library/react
npm ERR! #testing-library/react#"^12.0.0" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See /home/psn/.npm/eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/psn/.npm/_logs/2022-04-12T07_12_21_032Z-debug-0.log
`npm install --no-audit --save #testing-library/jest-dom#^5.14.1 #testing-
library/react#^12.0.0 #testing-library/user-event#^13.2.1 web-vitals#^2.1.0` failed
Sounds like you are running npx create-react-app command in a project that already includes react. Try running npm install instead.
If that does not work try to remove your node_modules folder and run npm install again.
You can try the following:
Delete both node_modules and package-lock.json
Run npm i web-vitals --save-dev
Run npm install
I want to run a blockchain application, but I got this error.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! scrypt#6.0.3 install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the scrypt#6.0.3 install script.
npm ERR! This is probably not a problem with npm.
There is likely additional logging output above.
I have tried deleting node_modules, npm cache verify and npm install again. I have uninstalled and reinstalled npm and nodejs. My npm version is 6.12.0 and node version v12.13.0
https://github.com/ethereum/web3.js/issues/1066#issuecomment-338841841
From this link:
I've solved this using the following steps
npm install --global --production windows-build-tools
node-gyp configure --msvs_version=2015
npm config set python /path/to/executable/python2.7
npm install web3 --save
And also, I think that you can follow steps to fix node-gyp:
https://github.com/nodejs/node-gyp
Believe or not,
use: sudo npm ...
It worked for me
I know this is an old one, but for anyone hung on this one now, what solved this for me was downgrading to node v10.24.1 & npm v6.14.12. Seems to be an issue with newer node versions.
sudo apt-get update -y
sudo apt-get remove -y gyp
sudo apt-get install -y curl bzip2 build-essential g++ python3 git make gcc gcc-multilib node-gyp
sudo apt-get install -y pkg-config xserver-xorg-dev libxext-dev pkg-config libxi-dev libglu1-mesa-dev libglew-dev
sudo npm install prebuild-install node-pre-gyp node-gyp -g
if show already exist then use --force flag while installing npm package
if then also not solve then try install package using "sudo npm i "
for more information see https://github.com/zodern/meteor-up/issues/683
I am using:
node -v
v10.15.3
npm -v
6.4.1
I have tried below mentioned command
command: npm i -g angular/cli
Error while executing: npm ERR! /usr/local/bin/git ls-remote -h -t
ssh://git#github.com/angular/cli.git
command: npm i -g #angular/cli
npm ERR! path /Users/admin/.node_modules/bin/ng npm ERR! code EEXIST
npm ERR! Refusing to delete /Users/admin/.node_modules/bin/ng:
../lib/node_modules/angular-cli/bin/ng symlink target is not
controlled by npm
/Users/admin/.node_modules/lib/node_modules/#angular/cli npm ERR! File
exists: /Users/admin/.node_modules/bin/ng npm ERR! Move it away, and
try again.
Make sure you have the correct path in Enviroment variable -> user variable like this
In this case my npm folder are located at
C:\Users\phuc.ngo\AppData\Roaming\npm
The npm folder is where everything you install can be found like angular cli, webpack, etc...
You need to try installing angular with admin previledge and try to install it globally with -g
npm install -g #angular/cli
after installation check the angular version
ng --version
I am trying to install yeoman but I am getting the following error messages:
I did install node.js and npm (latest version),now I am doing this
npm install -g yo grunt-cli bower
and
npm install -g yo
but I get the following error messages
npm http GET https://registry.npmjs.org/yo
npm http 200 https://registry.npmjs.org/yo
npm ERR! Error: No compatible version found: yo
npm ERR! No valid targets found.
npm ERR! Perhaps not compatible with your version of node?
npm ERR! at installTargetsError (/usr/share/npm/lib/cache.js:488:10)
npm ERR! at next_ (/usr/share/npm/lib/cache.js:438:17)
npm ERR! at next (/usr/share/npm/lib/cache.js:415:44)
npm ERR! at /usr/share/npm/lib/cache.js:408:5
npm ERR! at saved (/usr/share/npm/lib/utils/npm-registry-client/get.js:147:7)
npm ERR! at Object.oncomplete (/usr/lib/nodejs/graceful-fs.js:230:7)
npm ERR! You may report this log at:
npm ERR! <http://bugs.debian.org/npm>
npm ERR! or use
npm ERR! reportbug --attach /home/siddhartha/npm-debug.log npm
npm ERR!
npm ERR! System Linux 3.8.0-19-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install" "-g" "yo"
npm ERR! cwd /home/siddhartha
npm ERR! node -v v0.6.19
npm ERR! npm -v 1.1.4
npm ERR! message No compatible version found: yo
npm ERR! message No valid targets found.
npm ERR! message Perhaps not compatible with your version of node?
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/siddhartha/npm-debug.log
npm not ok
What is wrong? Is it something with my linux system or with npm or with node.js? I need yeoman up and running soon but I am stuck.
You might try reading the error message:
npm ERR! Perhaps not compatible with your version of node?
Yeoman requires Node >=0.8, but you have Node 0.6:
npm ERR! node -v v0.6.19
Upgrading to latest stable Node should do it.
sudo apt-get install node -y
I am using Ubuntu 12.10.
I had the same issue.
I am going to describe my exact fixes for
npm install -g yo
Yeoman requires node version >= 0.8
Because of permissions, I needed to use sudo npm install -g yo
The steps are:
sudo apt-get install python-software-properties -y
sudo apt-get install software-properties-common -y
sudo add-apt-repository ppa:chris-lea/node.js
sudo apt-get update -y
sudo apt-get install nodejs -y
sudo npm install -g yo
install nodejs is to update the node to the latest version
add-apt-repository is needed for a better repository to update the nodejs
python-software-properties and software-properties-common are for add-apt-repository
For references:
See https://stackoverflow.com/a/16032073/80353 which explains why you need to install either the python or the software to run add-apt-repository
See https://stackoverflow.com/a/16303380/80353 which inspires the general steps