angular-cli just quits during installation:
(myapp)vagrant@myapp-local:/vagrant$ sudo npm install -g angular-cli
npm WARN deprecated [email protected]: graceful-fs v3.0.0 and before will fail on node releases >= v7.0. Please update to graceful-fs@^4.0.0 as soon as possible. Use 'npm ls graceful-fs' to find it in the tree.
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]: This package is discontinued. Use lodash@^4.0.0.
(myapp)vagrant@myapp-local:/vagrant$ l mapToRegistry uri https://registry.npmjs.org/serve-static
(myapp)vagrant@myapp-local:/vagrant$ ng
The program 'ng' is currently not installed. To run 'ng' please ask your administrator to install the package 'ng-common'
It seems I have latest versions of both node and npm:
(myapp)vagrant@myapp-local:/vagrant$ npm -v
3.10.9
(myapp)vagrant@myapp-local:/vagrant$ node -v
v6.9.1
asked Nov 11, 2016 at 10:48
Dmitrii Mikhailov
5,2617 gold badges45 silver badges74 bronze badges
2 Answers 2
Resolved: So the issue was of memory of vagrant machine I increased it and it worked.
config.vm.provider "virtualbox" do |vb|
vb.memory = "2048"
end
At last step I had to do:
sudo ln -s /home/vagrant/node-v6.9.1-linux-x64/lib/node_modules/angular-cli/bin/ng /usr/bin/ng
answered Nov 11, 2016 at 13:36
Atta Ur Rehman
4765 silver badges9 bronze badges
Sign up to request clarification or add additional context in comments.
1 Comment
Dmitrii Mikhailov
So it's not just me. Thanks. You probably should use it just as comment to my question, so that I could flag it as important because it's not an answer after all.
The problem is that NPM3 is needed. It's not currently mentioned on the readme check this link. Just execute npm install -g npm3 and then use npm3 in place of npm to install or just update npm to the latest version. hope this will work.
Updated
- Try to clean cache -
npm cache clean, - Uninstall angular-cli -
npm uninstall -g angular-cli - Install again
npm install -g angular-cli. - Worse case install
angualr cliwith a-forceflag like this -npm install -g -f angular-cli
answered Nov 11, 2016 at 11:00
Keshan Nageswaran
8,2064 gold badges30 silver badges45 bronze badges
3 Comments
Dmitrii Mikhailov
I think there's no difference between using
npm3 command instead of npm if I already have npm=3.10.9 installed as shown in my question. Anyway, I tried to do what you advised and it didn't work.Keshan Nageswaran
@DmitryMikhaylov Try to clean cache
npm cache clean, uninstall angular-cli npm uninstall -g angular-cli & install again npm install -g angular-cli. Worse case install angualr cli with a -force flag like this npm install -g -f angular-cliDmitrii Mikhailov
Thanks, but result is the same after I cleaned cache, removed the angular-cli and reinstalled it with
-f optionlang-js
sudo ng