Skip to content

ng new does not show help from custom schematic #13681

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
vakrilov opened this issue Feb 15, 2019 · 3 comments
Closed

ng new does not show help from custom schematic #13681

vakrilov opened this issue Feb 15, 2019 · 3 comments
Labels
area: @angular/cli freq1: low Only reported by a handful of users who observe it rarely severity3: broken
Milestone

Comments

@vakrilov
Copy link
Contributor

vakrilov commented Feb 15, 2019

🐞 Bug report

Command (mark with an x)

- [x] new
- [ ] build
- [ ] serve
- [ ] test
- [ ] e2e
- [ ] generate
- [ ] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc

Is this a regression?

Yes, the previous version in which this bug was not present was: `6.1.3`

Description

When executing:

ng new -c=<custom-collection> --help

The help displayed is not the help from the ng-new schematic in the custom collection. The help from @schematics/angular is displayed instead.

🔬 Minimal Reproduction

I have reproduced it with @nativescript/schematis package:

npm i -g @nativescript/schematics
ng new -c=@nativescript/schematics --help

Expected: Print the help for @nativescript/schematics ng-new
Actual: Print the help for @schematics/angular
Note: Using @angular/[email protected] prints the correct help

🌍 Your Environment


Package                      Version
------------------------------------------------------
@angular-devkit/architect    0.13.1
@angular-devkit/core         7.3.1
@angular-devkit/schematics   7.3.1
@schematics/angular          7.3.1
@schematics/update           0.13.1
rxjs                         6.3.3
typescript                   3.2.4

Anything else relevant?
Debugging the issue led me to this place in the angular cli code. schematicName is defaulted to ng-new when executing ng new. However, the options.collection(if such option is provided) should used to load the collection schema and description.

Issue was reported here also: NativeScript/nativescript-schematics#157

@alan-agius4 alan-agius4 added freq1: low Only reported by a handful of users who observe it rarely severity3: broken area: @angular/cli labels Feb 15, 2019
@ngbot ngbot bot added this to the needsTriage milestone Feb 15, 2019
@cexbrayat
Copy link
Member

cexbrayat commented Jun 14, 2019

@alan-agius4 Looks like this is no longer an issue. You probably fixed it with #14530 right?

@alan-agius4
Copy link
Collaborator

Thanks for reporting this issue. This issue is now obsolete due to changes in the recent releases. Please update to the most recent Angular CLI version.

If the problem persists after upgrading, please open a new issue, provide a simple repository reproducing the problem, and describe the difference between the expected and current behavior.

@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 9, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area: @angular/cli freq1: low Only reported by a handful of users who observe it rarely severity3: broken
Projects
None yet
Development

No branches or pull requests

3 participants