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 project file:
<TargetFramework>net462</TargetFramework> <OutputPath>/build/debug/<OutputPath>
The actual output folder will resolve to /build/debug/net462/
, not /build/debug/
like in the older versions. How do I solve this without workarounds like moving things around with post build actions?
Right-click on your project in solution explorer and select Unload Project. Right-click on the project (tagged as unavailable in solution explorer) and click "Edit yourproj. csproj". This will open up your CSPROJ file for editing.
A CSPROJ file is a C# (C Sharp) programming project file created by Microsoft Visual Studio. It contains XML-formatted text that lists a project's included files and compilation options. Developers compile CSPROJ files using MSBuild (the Microsoft Build Engine).
What I often in Visual Studio 2017 RC3 to edit the csproj file, is: Right click on the project title in the Solution Explorer window. Select the option "Edit [project name]. csproj" to open the csproj file in the code editor window. Show activity on this post.
The solution is to use AppendTargetFrameworkToOutputPath
https://www.tabsoverspaces.com/233608-stopping-msbuild-appending-targetframework-to-outputpath/
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With