VS2013 有一个错误,即 NuGet 会将包添加为挂起的更改,即使您使用 .tfignore 告诉它不要这样做.有一个 workaround,但它不适用于 VS2015/NuGet3,并且 NuGet 又回到了它的旧技巧.是否有Nu"解决方法?:-)
Microsoft Connect 项目:NuGet 将包添加到 TFS,尽管 .tfignore
解决方案看起来这个问题在 - 至少更新到这个版本对我有用.
关于这个问题的讨论可以在这里找到,建议更新从 NuGet 3.1 到 3.2 RC.
更新
该扩展的 3.2 版现已发布(找到 此处),其中包括此修复程序.
澄清
要完成这项工作,您需要两件事:
如 文档:
NuGet 首先从默认位置加载 NuGet.config,然后加载任何名为 NuGet.config 的文件,从当前驱动器的根目录开始,到当前目录结束.
这意味着您可以在 您的用户配置文件的默认配置文件(找到在 %APPDATA%NuGetNuGet.Config)或解决方案目录中的 NuGet 配置文件中,例如 MySolution.NuGetNuGet.config.p>
VS2013 had a bug where NuGet would add packages as pending changes, even if you told it not to with .tfignore. There was a workaround, but it doesn't work with VS2015/NuGet3, and NuGet is back to its old tricks. Is there a "Nu" workaround? :-)
Microsoft Connect item: NuGet adds packages to TFS despite .tfignore
解决方案It looks like this is fixed in version 3.2 RC of the NuGet Visual Studio 2015 Extension - updating to this version worked for me, at least.
A discussion about this issue can be found here where it is recommended to update from NuGet 3.1 to 3.2 RC.
Update
Version 3.2 of the extension has now been released (found here) which includes this fix.
Clarification
To get this working you need two things:
As indicated in the docs:
NuGet first loads NuGet.config from the default location, then loads any file named NuGet.config starting from the root of the current drive and ending in the current directory.
This means that you can specify <solution><add key="disableSourceControlIntegration" value="true" /></solution> in the default config file for your user profile (found at %APPDATA%NuGetNuGet.Config) or in the NuGet config file in your solution directory, e.g., MySolution.NuGetNuGet.config.
更多推荐
如何防止 VS2015 NuGet 将包添加到 TFS
发布评论