我使用新的 NetSDK 格式创建了一个 C# 项目。通配符适用于其他情况:
<ItemGroup>
<None Include="Miscellaneous\*.misc" CopyToOutputDirectory="Always" />
</ItemGroup>
但是,通配符似乎不适用于Reference
标签:
<ItemGroup>
<!-- THIS DOES NOT WORK -->
<Reference Include="Company.Misc.*" HintPath="bin\Company.Misc.*.dll" />
<!-- THIS DOES WORK -->
<Reference Include="Company.Misc.A" HintPath="bin\Company.Misc.A.dll" />
<Reference Include="Company.Misc.B" HintPath="bin\Company.Misc.B.dll" />
</ItemGroup>
不确定是否有办法自动从 bin\ 目录中提取所有项目作为参考,以便显示在“依赖项”下?