Skip to content

Update migrate-only requires to argument #24510

Closed

Description

@bgotink

Command

update

Is this a regression?

  • Yes, this behavior used to work in the previous version

The previous version in which this bug was not present was

13.x

Description

Using ng update --migrate-only --from <version> <name> used to work:

$ NG_DISABLE_VERSION_CHECK=1 yarn dlx --package @angular/[email protected] \
      ng update --migrate-only --from 14.0.0 @angular/cdk
Using package manager: 'yarn'
Collecting installed dependencies...
Found 74 dependencies.
** Executing migrations of package '@angular/cdk' **

❯ Updates the Angular CDK to v15.
...

The docs also point to this:

$ yarn run -TB ng update --help
ng update [packages..]

...
      --to              Version up to which to apply migrations. Only available with a single
                        package being updated, and only with 'migrate-only' option. Requires 'from'
                        to be specified. Default to the installed version detected.         [string]
...

Minimal Reproduction

$ ng update --migrate-only --from 14.0.0 @angular/cdk

Exception or Error

Error: Missing dependent arguments:
 from -> to

Your Environment

_                      _                 ____ _     ___
    / \   _ __   __ _ _   _| | __ _ _ __     / ___| |   |_ _|
   / △ \ | '_ \ / _` | | | | |/ _` | '__|   | |   | |    | |
  / ___ \| | | | (_| | |_| | | (_| | |      | |___| |___ | |
 /_/   \_\_| |_|\__, |\__,_|_|\__,_|_|       \____|_____|___|
                |___/
    

Angular CLI: 15.0.0
Node: 16.16.0
Package Manager: yarn 3.2.4
OS: darwin x64

Angular: 15.0.0
... cdk, cli, common, compiler, compiler-cli, core, elements
... forms, localize, platform-browser, platform-browser-dynamic
... router

Package                         Version
---------------------------------------------------------
@angular-devkit/architect       0.1500.0
@angular-devkit/build-angular   15.0.0
@angular-devkit/core            15.0.0
@angular-devkit/schematics      15.0.0
@schematics/angular             15.0.0
rxjs                            7.5.5
typescript                      4.8.2

Anything else relevant?

No response

Activity

  1. added
    freq1: low
    on Jan 10, 2023
  2. added 2 commits that reference this issue on Jan 11, 2023
    b3c2d6c
    e77fd7a
  3. added 2 commits that reference this issue on Jan 13, 2023
    697df4f
    5d9fd78
  4. angular-automatic-lock-bot commented on Feb 13, 2023

    @angular-automatic-lock-bot

    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.

  5. locked and limited conversation to collaborators on Feb 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: @angular/clifreq1: lowseverity5: regressiontype: bug/fix

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions