-
Notifications
You must be signed in to change notification settings - Fork 12k
defaultCollection is relative to where cmd is run not angular.json #23136
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
Comments
…teas of current working directory Relative schematics referenced in `angular.json` `schematicCollections` and `defaultCollection` were always resolved from the current working directory, which is not correct and caused the collection not to be resolved when the this is different from the location of the workspace config. Closes angular#23136
…tead of current working directory Relative schematics referenced in `angular.json` `schematicCollections` and `defaultCollection` were always resolved from the current working directory, which is not correct and caused the collection not to be resolved when the this is different from the location of the workspace config. Closes angular#23136
…tead of current working directory Relative schematics referenced in `angular.json` `schematicCollections` and `defaultCollection` were always resolved from the current working directory, which is not correct and caused the collection not to be resolved when the this is different from the location of the workspace config. Closes #23136
…tead of current working directory Relative schematics referenced in `angular.json` `schematicCollections` and `defaultCollection` were always resolved from the current working directory, which is not correct and caused the collection not to be resolved when the this is different from the location of the workspace config. Closes #23136 (cherry picked from commit c71832f)
…tead of current working directory Relative schematics referenced in `angular.json` `schematicCollections` and `defaultCollection` were always resolved from the current working directory, which is not correct and caused the collection not to be resolved when the this is different from the location of the workspace config. Closes angular#23136
…tead of current working directory Relative schematics referenced in `angular.json` `schematicCollections` and `defaultCollection` were always resolved from the current working directory, which is not correct and caused the collection not to be resolved when the this is different from the location of the workspace config. Closes #23136
@alan-agius4 I tried your fix. Now it works, but it works differently between default and custom schematics. This ignores any subfolders now. In the screenshot, I ran the command twice from the same folder, but the components were created in different folders: I commit example: https://github.com/kvart714/ng-g-c-bug |
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
🐞 Bug report
Command (mark with an
x
)Is this a regression?
No, it's is duplicate of #15014
Description
🔬 Minimal Reproduction
Repo example: https://github.com/kvart714/ng-g-c-bug
It includes custom schematic.
Command
ng g c
works in project folder, but not works in nested folders due to relative path.The text was updated successfully, but these errors were encountered: