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

Global cli install keeps breaking because of Installing a temporary version to perform the update #16010

Closed
dottodot opened this issue Nov 1, 2019 · 3 comments · Fixed by #16011

Comments

@dottodot
Copy link

dottodot commented Nov 1, 2019

Using the latest version of cli I keep getting this warning

Your global Angular CLI version (8.3.17) is greater than your local
version (8.3.16). The local Angular CLI version is used.

To disable this warning use "ng config -g cli.warnings.versionMismatch false".
The installed Angular CLI version is older than the latest published version.
Installing a temporary version to perform the update.

and after this if I try using ng I then get an error of

bash: /usr/local/bin/ng: No such file or directory

If I then run

npm i -g  @angular/cli

I get an error of

npm ERR! Refusing to delete /usr/local/bin/ng: ../../../private/var/folders/h_/nr3rbk_917v1v7f01_tpt4_80000gn/T/.ng-temp-packages-n6S6NB/node_modules/.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.

so my only way around is to remove /usr/local/bin/ng and then install again.

I have to do this every time I run ng update and it's been and issue since v8.3.13

@alan-agius4
Copy link
Collaborator

@dottodot, can you please provide the output of ng version?

@dottodot
Copy link
Author

dottodot commented Nov 1, 2019

yes it's

Angular CLI: 8.3.17
Node: 10.17.0
OS: darwin x64
Angular: 8.2.13
... animations, common, compiler, compiler-cli, core, forms
... language-service, platform-browser, platform-browser-dynamic
... platform-server, router, service-worker

Package                                    Version
--------------------------------------------------------------------
@angular-devkit/architect                  0.803.17
@angular-devkit/build-angular              0.803.17
@angular-devkit/build-optimizer            0.803.17
@angular-devkit/build-webpack              0.803.17
@angular-devkit/core                       8.3.17
@angular-devkit/schematics                 8.3.17
@angular/cdk                               8.2.3
@angular/cli                               8.3.17
@angular/flex-layout                       8.0.0-beta.27
@angular/material                          8.2.3
@angular/material-moment-adapter           8.2.3
@angular/pwa                               0.801.3
@ngtools/webpack                           8.3.17
@nguniversal/common                        8.1.1
@nguniversal/express-engine                8.1.1
@nguniversal/module-map-ngfactory-loader   8.1.1
@schematics/angular                        8.1.3
@schematics/update                         0.803.17
rxjs                                       6.5.3
typescript                                 3.5.3
webpack                                    4.39.2

@alan-agius4 alan-agius4 modified the milestones: Backlog, 9.0.x Nov 1, 2019
@alan-agius4 alan-agius4 changed the title Globla cli install keeps breaking because of Installing a temporary version to perform the update Global cli install keeps breaking because of Installing a temporary version to perform the update Nov 4, 2019
vikerman pushed a commit that referenced this issue Nov 4, 2019
vikerman pushed a commit that referenced this issue Nov 4, 2019
vikerman pushed a commit that referenced this issue Nov 5, 2019
@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 Dec 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.