13
在我的一些文件的csproj我有这个,但一些不要:EnsureNuGetPackageBuildImports目标是什么?
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
<PropertyGroup>
<ErrorText>This project references NuGet package(s) that are missing on this computer. Enable NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
</PropertyGroup>
<Error Condition="!Exists('$(SolutionDir)\.nuget\NuGet.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\.nuget\NuGet.targets'))" />
</Target>
到底是什么这一点,我为什么需要它?我的其他项目正在恢复他们的软件包就好了没有它。
我正在使用VS2013和NuGet 2.8。
我想知道“ctaggart/nuget”存储库(你链接的)是否真的准确。也许你会链接到“NuGet/NuGet.Client”。它还有[MSBuildProjectSystem.cs文件](https://github.com/NuGet/NuGet.Client/blob/fee9da08b687e9d18073243d46f6d46ad660dd4c/src/NuGet.Clients/NuGet.CommandLine/Common/MSBuildProjectSystem.cs)与EnsureNuGetPackageBuildImports和它似乎是官方的nuget来源。 –