Skip to content

rc.2 doesn't preserve "yarn" as the preferred package manager during cli update #10225

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

Closed
IgorMinar opened this issue Apr 7, 2018 · 1 comment
Milestone

Comments

@IgorMinar
Copy link
Contributor

IgorMinar commented Apr 7, 2018

Versions

Angular CLI: 6.0.0-rc.2
Node: 8.9.4
OS: darwin x64
Angular: 6.0.0-rc.3
... animations, common, compiler, compiler-cli, core, elements
... forms, http, platform-browser, platform-browser-dynamic
... platform-server, router

@angular/cdk: 6.0.0-rc.1
@angular/cli: 6.0.0-rc.2
@angular/material: 6.0.0-rc.1

Repro steps

  • get a yarn based 1.7.3 project
  • update cli to 6.rc2
  • ng update @angular/cli --migrate-only --from=1.7.3

Observed behavior

angular.json doesn't contain "yarn" as a preferred package manager setting

Desired behavior

yarn preference should be preserved during update

Mention any other details that might be useful (optional)

once this goes wrong, any subsequent ng updates e.g. ng update @angular/material work incorrectly because they use npm rather than yarn.

Workaround

Manually edit angular.json to add the config option:

{
  "version": 1,
  "cli": {
    "packageManager": "yarn"
  },
  ...

One can also set user-wide setting via:

ng config --global cli.packageManager '"yarn"'
@hansl hansl self-assigned this Apr 12, 2018
@hansl hansl added this to the v6.0.0 milestone Apr 12, 2018
@hansl hansl removed the 6.0.0-rc label Apr 12, 2018
@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

3 participants