How do you only update NuGet packages with specific identifiers?

According to NuGet Documentation :

Refresh Team

Update packages to the latest available versions. This command also updates NuGet.exe itself.

Using nuget update <packages.config|solution>

Options:

Id - The identifiers of the packages to update.

This indicates that the ID parameter is the package identifier s for the update. How do you provide multiple identifiers?

It works:

 NuGet.exe update "MySln.sln" -RepositoryPath "MyRepoPath" -id Ref1 

... but how do you also fool Ref2? This fails:

 NuGet.exe update "MySln.sln" -RepositoryPath "MyRepoPath" -id Ref1,Ref2 

I am trying to update a subset of packages and prevent the need for a large number of calls in NuGet.exe.

+7
source share
1 answer

You can specify the -id option several times:

 NuGet.exe update "MySln.sln" -RepositoryPath "MyRepoPath" -id Ref1 -id Ref2 
+6
source

All Articles