Skip to content

Improve error message for project-specific ng commands outside a project #23481

Closed

Description

@dgp1130

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:

$ ng serve
This is a monorepository workspace and there are many projects you can serve. Run `ng serve <project>` to serve a specific application. Available projects are:
* my-app
* my-lib
* my-other-lib

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.

Activity

  1. added
    action: merge
    freq1: low
    and removed
    action: merge
    on Jun 30, 2022
  2. added 4 commits that reference this issue on Jul 1, 2022
    3347c6e
    d393038
    c14da57
    1e16785
  3. self-assigned this
    on Jul 1, 2022
  4. added a commit that references this issue on Jul 1, 2022
    ff0f56e
  5. added 2 commits that reference this issue on Jul 1, 2022
    dbe0dc1
    094aa16
  6. angular-automatic-lock-bot commented on Aug 1, 2022

    @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.

  7. locked and limited conversation to collaborators on Aug 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area: @angular/clifreq1: lowseverity2: inconvenienttype: bug/fix

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions