@atripp
Thanks for your reply , following your instructions, the problem has been resolved in vs2022 , cmd like this:
dotnet nuget add source https://someServer/myTeam -n myTeam -u myUsername -p myPassword --store-password-in-clear-text
And, another way to solve (tested in VS2017 and VS2022) can add a nuget.config
in solution root directory:
<configuration>
<packageSources>
<add key="mynuget" value="my source url" protocolVersion="3"/>
</packageSources>
<packageSourceCredentials>
<mynuget>
<add key="Username" value="myuser" />
<add key="ClearTextPassword" value="mypwd" />
</mynuget>
</packageSourceCredentials>
</configuration>
So kind of you,thanks again.