Navigation Menu

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot install angular-cli #7556

Closed
kkanedaa opened this issue Aug 31, 2017 · 8 comments
Closed

Cannot install angular-cli #7556

kkanedaa opened this issue Aug 31, 2017 · 8 comments

Comments

@kkanedaa
Copy link

kkanedaa commented Aug 31, 2017

I am trying to install angular-cli (v.1.0). I have two Mac computers, on which one device (MacBook Pro Mid-2015) the installation was successful. But on my other Mac (iMac Early-2011), I get the following error message:

`npm ERR! Darwin 16.7.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "-g" "-f" "@angular/cli"
npm ERR! node v6.11.2
npm ERR! npm v3.10.10
npm ERR! path ../lib/node_modules/@angular/cli/bin/ng
npm ERR! code EACCES
npm ERR! errno -13
npm ERR! syscall symlink

npm ERR! Error: EACCES: permission denied, symlink '../lib/node_modules/@angular/cli/bin/ng' -> '/usr/local/bin/ng'
npm ERR! at Error (native)
npm ERR! { Error: EACCES: permission denied, symlink '../lib/node_modules/@angular/cli/bin/ng' -> '/usr/local/bin/ng'
npm ERR! at Error (native)
npm ERR! errno: -13,
npm ERR! code: 'EACCES',
npm ERR! syscall: 'symlink',
npm ERR! path: '../lib/node_modules/@angular/cli/bin/ng',
npm ERR! dest: '/usr/local/bin/ng' }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.

npm ERR! Please include the following file with any support request:
npm ERR! /Users/Kaneda/npm-debug.log
npm ERR! code 1`

I used the following command to install it (without success):

npm install -g -f @angular/cli

After it failed, I tried to clean the cache, uninstall it, and try one more time - again without success (same error message as above):

npm cache clean
npm uninstall -g @angular/cli
npm install -g @angular/cli

In the error message, it says permission denied, but I am the only user on this mac with admin privileges.

Does anyone know what is wrong and why I cannot install it?

Thanks in advance.

@chrste90
Copy link

Try running the command as root:
sudo npm install -g @angular/cli

@kkanedaa
Copy link
Author

@chris1308 Thanks a lot! Worked flawlessly :) My gratitudes!

@yahyaKacem
Copy link

@kkanedaa please close this issue since it's resolved.

@kkanedaa
Copy link
Author

@yahyaKacem Sorry about that; closed :)

@ghost ghost mentioned this issue Feb 3, 2018
@naivedeveloper95
Copy link

naivedeveloper95 commented Feb 15, 2018

I am trying to install angular-cli on linux lite. I have installed nodejs.
root@LinuxLite-Notebook-PC:~# node -v
v9.5.0
What should I do? How to intsall angular-cli on linux lite. I ran the sudo npm install -g @angular/cli command, got errors that I have listed below.

root@LinuxLite-Notebook-PC:~# sudo npm install -g @angular/cli
npm WARN ajv-keywords@3.1.0 requires a peer of ajv@^6.0.0 but none is installed. You must install peer dependencies yourself.

npm ERR! path /usr/local/bin/ng
npm ERR! code EEXIST
npm ERR! Refusing to delete /usr/local/bin/ng: ../lib/node_modules/angular-cli/bin/ng symlink target is not controlled by npm /usr/local/lib/node_modules/@angular/cli
npm ERR! File exists: /usr/local/bin/ng
npm ERR! Move it away, and try again.

npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2018-02-15T10_49_29_898Z-debug.log

@NataliaAvila
Copy link

I have the same problem, did someone find the solution?

@naderalbes
Copy link

I have the same problem

@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants
@yahyaKacem @NataliaAvila @chrste90 @naderalbes @naivedeveloper95 @kkanedaa and others