[英]How to exclude a subdirectory and contents from a nuget package
所以我有一個網站,我正在嘗試為Octopus Deploy打包。
我有以下文件夾結構:
Web | Views | WantThis Dontwantthis WantThis1 WantThis2 ... (lots more) Scripts
我試圖排除“Dontwantthisfolder”
所以我的nuspec看起來像這樣:
... <file src="..\\Web\\Views\\**\\*.*" exclude="**\\Dontwantthis\\**" target="web\\Views" /> ...
雖然它不起作用,我仍然得到“Dontwantthis”文件夾。
誰知道我怎么能做到這一點?
你很親密 試試這個:
<files>
<file src="..\Web\Views\**\*.*" exclude="..\Web\Views\DontWantThis\*" target="Web\Views" />
</files>
我能夠通過以下文件系統結構來排除DontWantThis
:
Root
|
Source
|
Test.nuspec
Web
|
Scripts
|
Script.js
Views
|
DontWantThis
|
Bad.cshml
WantThis
|
Good.cshtml
...
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.