[英]Multiple locations for NuGet Restore
I know I can add different locations to a nuget.targets file, and I know NuGet will work by reading a file share. 我知道我可以在nuget.targets文件中添加不同的位置,并且我知道NuGet将通过读取文件共享来工作。
Can I put a file share in a nuget.targets file however? 我可以将文件共享放在nuget.targets文件中吗?
This is so my build server can use the nuget.targets file to pull the nupkg's. 这样我的构建服务器可以使用nuget.targets文件提取nupkg的文件。
I tried this but doesn't seem to work: 我尝试了这个,但似乎没有用:
<ItemGroup Condition=" '$(PackageSources)' == '' ">
<!-- Package sources used to restore packages. By default will used the registered sources under %APPDATA%\NuGet\NuGet.Config -->
<PackageSource Include="https://nuget.org/api/v2/" />
<PackageSource Include="//jcwinvm/Packages" />
</ItemGroup>
尝试使用反斜杠:
<PackageSource Include="\\jcwinvm\Packages" />
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.