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

Invoke dotnet nuget why directly through API #44614

Merged
merged 2 commits into from
Jan 4, 2025

Conversation

zivkan
Copy link
Member

@zivkan zivkan commented Nov 4, 2024

The initial version of dotnet nuget why required two arguments, the first being the solution, project, or directory to run as. In NuGet/NuGet.Client#5969 I made it optional, using the current directory when not provided. However, this repo has a duplicate of the CLI parser to aid tab-completion. Therefore, even when the command works, there's an error message:

image

Following NuGet/NuGet.Client#6118, this PR changes the dotnet CLI to get the CLI parser from NuGet directly (this command uses System.CommandLine), so dotnet nuget why no longer needs to be invoked though the NuGet.CommandLine.XPlat console app. Therefore, any future changes to dotnet nuget why will apply automatically on NuGet insertion, rather than needing duplicate CLI parsing changes in both repos.

@zivkan zivkan requested a review from a team as a code owner November 4, 2024 04:03
@dotnet-issue-labeler dotnet-issue-labeler bot added Area-Infrastructure untriaged Request triage from a team member labels Nov 4, 2024
Copy link
Member

@baronfel baronfel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Love to see this kind of deeper integration! One note about the help that we may need to create a bridge for in some way.

@nkolev92
Copy link
Contributor

nkolev92 commented Nov 4, 2024

I looked at this and the changes look reasonable as far as the NuGet side goes.

@nkolev92
Copy link
Contributor

nkolev92 commented Dec 5, 2024

I'm guessing this PR was accidentally closed by GH's keywords, but it's actually something that needs to be reopened, right @zivkan

@zivkan zivkan force-pushed the dotnet-nuget-why-command branch 2 times, most recently from 30f49f9 to e34bb9e Compare December 14, 2024 01:48
@zivkan zivkan force-pushed the dotnet-nuget-why-command branch from e34bb9e to bbfcb2a Compare December 14, 2024 01:53
@zivkan zivkan marked this pull request as ready for review December 14, 2024 01:54
@zivkan zivkan requested a review from baronfel December 14, 2024 01:54
@zivkan
Copy link
Member Author

zivkan commented Dec 18, 2024

@dotnet/nuget-team @dotnet/dotnet-cli This PR was opened a while ago, but it's ready for review now, please. It would be nice to get in time for 9.0.200.

The Mac test job appears to be timing out on all builds/prs, so I assume it's not a blocking issue for this PR.

Copy link
Member

@baronfel baronfel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Couldn't be more excited for this first step into deeper integration :)

@zivkan zivkan merged commit fe535b3 into dotnet:release/9.0.2xx Jan 4, 2025
28 of 31 checks passed
@zivkan zivkan deleted the dotnet-nuget-why-command branch January 4, 2025 00:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Infrastructure untriaged Request triage from a team member
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants