码迷,mamicode.com
首页 > Windows程序 > 详细

nuget.exe push won't use API Key

时间:2017-05-25 00:14:54      阅读:292      评论:0      收藏:0      [点我收藏+]

标签:href   min   using   add   provided   setting   change   work   for   

I had the same issue today on v3.4.3.855.
I set the api key using the required command, then when I ran the push I got this warning:

WARNING: No API Key was provided and no API Key could be found for ‘https://www.nuget.org/api/v2/package

and was asked to login using username and password.

So the issue for me was, when I ran: nuget SetApiKey abc...def, I noticed that in the config file ("%Appdata%\Roaming\Nuget\NuGet.Config") it added a key for https://www.nuget.org, when I changed to to the full path it worked fine -> https://www.nuget.org/api/v2/package

So the bug appears to be in the SetApiKey command, not setting the correct key (for the push case anyway)

 

nuget.exe setApiKey [key] -source https://www.nuget.org/api/v2/package

 

nuget.exe push won't use API Key

标签:href   min   using   add   provided   setting   change   work   for   

原文地址:http://www.cnblogs.com/lizhanglong/p/6901441.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!