Skip to content

fix: ng generate on default project #12931

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
klauskpm opened this issue Nov 11, 2018 · 2 comments
Closed

fix: ng generate on default project #12931

klauskpm opened this issue Nov 11, 2018 · 2 comments

Comments

@klauskpm
Copy link
Contributor

Bug Report or Feature Request (mark with an x)

- [x] bug report -> please search issues before submitting
- [ ] feature request

Command (mark with an x)

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

Versions

Angular CLI: 7.0.1
Node: 10.10.0
OS: darwin x64
Angular: 7.0.0
... animations, common, compiler, compiler-cli, core, forms
... http, language-service, platform-browser
... platform-browser-dynamic, router

Package                            Version
------------------------------------------------------------
@angular-devkit/architect          0.10.1
@angular-devkit/build-angular      0.10.1
@angular-devkit/build-ng-packagr   0.10.1
@angular-devkit/build-optimizer    0.10.1
@angular-devkit/build-webpack      0.10.1
@angular-devkit/core               7.0.1
@angular-devkit/schematics         7.0.1
@angular/cli                       7.0.1
@ngtools/json-schema               1.1.0
@ngtools/webpack                   7.0.1
@schematics/angular                7.0.1
@schematics/update                 0.10.1
ng-packagr                         4.3.1
rxjs                               6.3.3
typescript                         3.1.3
webpack                            4.19.1

Repro steps

  1. Create a workspace, generate a library and set it as the default project. Now generate a component without supplying a project. It will generate the component at src/app.

  2. Create a workspace without an application (--create-application false), generate a library and an application, and set the library as the default project. Now generate a component without supplying a project. It will generate the component at projects/my-lib.

Desired functionality

I think it would be better if it always used the default project.

@alan-agius4
Copy link
Collaborator

Duplicate of: #11111

@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

2 participants