Actually, it works well in my side and it will update all the nuget packages from packages.config
to the latest ones.
To remove the authentication from the nuget package source on VS IDE and make it not happen on the next time, you should add its info into global nuget.config
file so that it will not prompt next time. See this official document.
Step
1) close VS, open the nuget.config from C:\Users\xxx(current user)\AppData\Roaming\NuGet
add these:
<configuration>
<packageSources>
<add key="xxxx(your nuget package source)" value="xxxxxx" />
</packageSources>
<packageSourceCredentials>
<xxx(your nuget package source)>
<add key="Username" value="xxxx" />
<add key="Password" value="xxxx" />
</xxx(your nuget package source)>
</packageSourceCredentials>
</configuration>
2) Save the file and then restart VS to enable the new changes.
3) After that, you can remove the package source node in your command and it has already type in the global nuget.config
file. Every time you run the command, it will first search
any info under global nuget.config
file and if it has, you do not have to type under the command.
Run this:
$(SolutionDir)nuget\Nuget.exe update $(ProjectDir)packages.config -id <nuget package to update>
4) If it still does not update the packages.config
, you can try these:
delete the bin and obj folder, download the latest nuget.exe cli v5.7.0 and use the new version.
Besides, if you face any error messages under the update process, please share it with us.
This is a small demo about my test result:
