How do I set `OutputPath` in a Visual Studio 2017 project (new .csproj file format) without the target framework cluttering the resolved path?

后端 未结 2 613
执念已碎
执念已碎 2020-12-05 06:36

Setting OutputPath in the new Visual Studio 2017 project format automatically adds the target framework in the path. For example, if I have these set in the pro

相关标签:
2条回答
  • 2020-12-05 06:48

    The solution is to use AppendTargetFrameworkToOutputPath https://www.tabsoverspaces.com/233608-stopping-msbuild-appending-targetframework-to-outputpath/

    <AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
    
    0 讨论(0)
  • 2020-12-05 06:51

    The answer above is right, but you may also want to remove the runtime identifier:

    <AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
    <AppendRuntimeIdentifierToOutputPath>false</AppendRuntimeIdentifierToOutputPath>
    
    0 讨论(0)
提交回复
热议问题