我正在使用下面的 MSBuild 脚本编译解决方案,并且类库项目 .dll 正在文件夹 obj/Release 中创建,但依赖项目 dll 在那里不可用。并且 Bin\Release 文件夹也没有被创建。
<ItemGroup>
<PPTProjectToBuild Include="C:\TestProject\sln\Test.sln" />
</ItemGroup>
<MSBuild Projects="@(PPTProjectToBuild)" Properties="Configuration=Release;DebugType=None;DebugSymbols=false;OutputPath=$(PPTCompiledOutputDirPath);ReferencePath=$(ReferencePath)" ContinueOnError="ErrorAndStop"/>
最佳答案
将多个属性传递给 MSBuild 任务:“Configuration=Release;DebugType=None;DebugSymbols=false;OutputPath=$(PPTCompiledOutputDirPath);ReferencePath=$(ReferencePath)”
只需删除“OutputPath=$(PPTCompiledOutputDirPath);”部分从属性字符串中,您的 dll 将被放置到每个项目配置的位置。
如果您希望将构建输出放置在其他位置,只需将“OutputPath=”属性值设置为适当的位置即可。
关于c# - MSBuild : bin/release folder is not getting created,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49747450/