At the moment, the UI offers install-package instructions, for example:
PM> Install-Package Dapper -Version 1.50.1
With the new csproj system, I see a lot of people hand editing these, especially since the VS tooling is somewhat... hit and miss currently (especially for non-trivial scenarios). It would be nice if the website could include the equivalent <PackageReference> line (including version) for direct copy into csproj.
Thanks for the feedback. Agree only showing the instructions for PMC is not sufficient. Though PackageReference is not applicable to all the project systems, we should document (on the packages page or link from it) other ways of installing the package.
Added to the backlog.
Perhaps consider the dotnet cli experience as well? dotnet add package Dapper.
Yes, I would prefer to copy/paste a command like this:
dotnet add package -v 2.0.0-preview2-final Microsoft.EntityFrameworkCore.SqlServer
But what if it's a CLI tool? Then the command as well as the reference differ...
Isn't this fixed already? At least the "dotnet add..." command is part of the UI. Just wondering if there is anything left to do here.
Yepp. @skofman1 Can you close this?
While the .NET CLI command: dotnet add package.. is already added, the <PackageReference .. /> copy command is pending: https://github.com/NuGet/NuGetGallery/pull/5656#issuecomment-480959235
So may be we should wait till the above PR is merged.
Will close this as replica of https://github.com/NuGet/NuGetGallery/issues/5670