-
Notifications
You must be signed in to change notification settings - Fork 12k
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
Improve error message for project-specific ng
commands outside a project
#23481
Labels
2022Q3 Fixit
Candidates for the Q3 2022 fix-it
area: @angular/cli
freq1: low
Only reported by a handful of users who observe it rarely
severity2: inconvenient
type: bug/fix
Comments
alan-agius4
added
action: merge
The PR is ready for merge by the caretaker
type: bug/fix
freq1: low
Only reported by a handful of users who observe it rarely
severity2: inconvenient
and removed
action: merge
The PR is ready for merge by the caretaker
labels
Jun 30, 2022
alan-agius4
added a commit
to alan-agius4/angular-cli
that referenced
this issue
Jul 1, 2022
…ands when run outside of a project With this change we improve the error message when a project for command cannot be determined ``` Error: Cannot determine project for command. This is a multi-project workspace and more than one project supports this command. Run "ng build [project]" to execute the command for a specific project or change the current working directory to a project directory. Available projects are: - project-name-0 - project-name-1 - project-name-2 - project-name-3 - project-name-4 - project-name-5 - project-name-6 - project-name-7 - project-name-8 - project-name-9 ... ``` Closes angular#23481
alan-agius4
added a commit
to alan-agius4/angular-cli
that referenced
this issue
Jul 1, 2022
…ands when run outside of a project With this change we improve the error message when a project for command cannot be determined ``` Error: Cannot determine project for command. This is a multi-project workspace and more than one project supports this command. Run "ng build [project]" to execute the command for a specific project or change the current working directory to a project directory. Available projects are: - project-name-0 - project-name-1 - project-name-2 - project-name-3 - project-name-4 - project-name-5 - project-name-6 - project-name-7 - project-name-8 - project-name-9 ... ``` Closes angular#23481
alan-agius4
added a commit
to alan-agius4/angular-cli
that referenced
this issue
Jul 1, 2022
…ands when run outside of a project With this change we improve the error message when a project for command cannot be determined ``` Error: Cannot determine project for command. This is a multi-project workspace and more than one project supports this command. Run "ng build [project]" to execute the command for a specific project or change the current working directory to a project directory. Available projects are: - project-name-0 - project-name-1 - project-name-2 - project-name-3 - project-name-4 - project-name-5 - project-name-6 - project-name-7 - project-name-8 - project-name-9 ``` Closes angular#23481
alan-agius4
added a commit
to alan-agius4/angular-cli
that referenced
this issue
Jul 1, 2022
…ands when run outside of a project With this change we improve the error message when a project for command cannot be determined ``` Error: Cannot determine project for command. This is a multi-project workspace and more than one project supports this command. Run "ng build [project]" to execute the command for a specific project or change the current working directory to a project directory. Available projects are: - project-name-0 - project-name-1 - project-name-2 - project-name-3 - project-name-4 - project-name-5 - project-name-6 - project-name-7 - project-name-8 - project-name-9 ``` Closes angular#23481
alan-agius4
added a commit
to alan-agius4/angular-cli
that referenced
this issue
Jul 1, 2022
…ands when run outside of a project With this change we improve the error message when a project for command cannot be determined ``` Error: Cannot determine project for command. This is a multi-project workspace and more than one project supports this command. Run "ng build [project]" to execute the command for a specific project or change the current working directory to a project directory. Available projects are: - project-name-0 - project-name-1 - project-name-2 - project-name-3 - project-name-4 - project-name-5 - project-name-6 - project-name-7 - project-name-8 - project-name-9 ``` Closes angular#23481
clydin
pushed a commit
that referenced
this issue
Jul 1, 2022
…ands when run outside of a project With this change we improve the error message when a project for command cannot be determined ``` Error: Cannot determine project for command. This is a multi-project workspace and more than one project supports this command. Run "ng build [project]" to execute the command for a specific project or change the current working directory to a project directory. Available projects are: - project-name-0 - project-name-1 - project-name-2 - project-name-3 - project-name-4 - project-name-5 - project-name-6 - project-name-7 - project-name-8 - project-name-9 ``` Closes #23481
clydin
pushed a commit
that referenced
this issue
Jul 1, 2022
…ands when run outside of a project With this change we improve the error message when a project for command cannot be determined ``` Error: Cannot determine project for command. This is a multi-project workspace and more than one project supports this command. Run "ng build [project]" to execute the command for a specific project or change the current working directory to a project directory. Available projects are: - project-name-0 - project-name-1 - project-name-2 - project-name-3 - project-name-4 - project-name-5 - project-name-6 - project-name-7 - project-name-8 - project-name-9 ``` Closes #23481 (cherry picked from commit dbe0dc1)
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. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
2022Q3 Fixit
Candidates for the Q3 2022 fix-it
area: @angular/cli
freq1: low
Only reported by a handful of users who observe it rarely
severity2: inconvenient
type: bug/fix
Spin off from #23470.
Project-specific Angular CLI commands don't currently give a great error message when run in a workspace but outside a project. I forget the exact text but something along the lines of "No project available". We should improve this to clarify what we mean by project and ideally list out available projects in the workspace. Something like:
In really big workspaces we might want to limit this list so we don't explode the console. Maybe limit to 5 or 10 projects with a suggestion to look at
angular.json
for more.The text was updated successfully, but these errors were encountered: