Skip to content
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

feat(core): provide a hint when project.json has empty targets #22028

Merged
merged 1 commit into from
Feb 29, 2024

Conversation

jaysoo
Copy link
Member

@jaysoo jaysoo commented Feb 27, 2024

With Project Crystal, new projects are generated with empty targets in project.json. This is confusing for users that expect targets to be defined in project.json or nx.json.

This PR ensures that whenever the targets in project.json are empty, we add a hint for the user:

{
  "// targets": "to see all targets run: nx show project <name> --web`",
  "targets" {}
}

@jaysoo jaysoo requested a review from a team as a code owner February 27, 2024 21:15
@jaysoo jaysoo requested a review from FrozenPandaz February 27, 2024 21:15
Copy link

vercel bot commented Feb 27, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Updated (UTC)
nx-dev ⬜️ Ignored (Inspect) Visit Preview Feb 29, 2024 3:07am

@jaysoo jaysoo force-pushed the feat_empty_targets_hint branch 3 times, most recently from 4a0e555 to 6e50324 Compare February 27, 2024 21:36
@jaysoo jaysoo requested a review from a team as a code owner February 27, 2024 21:36
@jaysoo jaysoo requested a review from mandarini February 27, 2024 21:36
@jaysoo jaysoo force-pushed the feat_empty_targets_hint branch from 6e50324 to a57d631 Compare February 28, 2024 20:48
@jaysoo jaysoo force-pushed the feat_empty_targets_hint branch from a57d631 to 268a523 Compare February 28, 2024 23:00
@jaysoo jaysoo force-pushed the feat_empty_targets_hint branch from 268a523 to a9b1fe8 Compare February 29, 2024 03:06
@jaysoo jaysoo enabled auto-merge (squash) February 29, 2024 03:06
@jaysoo jaysoo merged commit c523d52 into master Feb 29, 2024
6 checks passed
@jaysoo jaysoo deleted the feat_empty_targets_hint branch February 29, 2024 05:12
Copy link

github-actions bot commented Mar 6, 2024

This pull request has already been merged/closed. If you experience issues related to these changes, please open a new issue referencing this pull request.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 6, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants