You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to publish a .net 6.0 console app to win-x64, osx-x64 and osx-arm64 using my csproj and various profiles defined before but all indicating using "Release", "ProduceSingleFile" and "SelfContained".
Please not the -c Release in the osx publish. I do not add them when publishing to osx... the publish process ALWAYS tries to retrieve singlefilehost from the DEBUG folder instead of the RELEASE one.
Adding -c Release allows bypassing the issue.
The text was updated successfully, but these errors were encountered:
I'm trying to publish a .net 6.0 console app to win-x64, osx-x64 and osx-arm64 using my csproj and various profiles defined before but all indicating using "Release", "ProduceSingleFile" and "SelfContained".
I've added the following inside my csproj:
<PropertyGroup> <OutputType>Exe</OutputType> <TargetFramework>net6.0</TargetFramework> <RuntimeIdentifiers>win-x64;osx-x64;osx-arm64</RuntimeIdentifiers> </PropertyGroup> <Target Name="PostBuild" AfterTargets="PostBuildEvent"> <Exec Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'" Command="dotnet publish -p:PublishProfile=win-x64 --no-build" /> <Exec Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'" Command="dotnet publish -c Release -p:PublishProfile=osx-x64 --no-build" /> <Exec Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'" Command="dotnet publish -c Release -p:PublishProfile=osx-arm64 --no-build" /> </Target>
Please not the -c Release in the osx publish. I do not add them when publishing to osx... the publish process ALWAYS tries to retrieve singlefilehost from the DEBUG folder instead of the RELEASE one.
Adding -c Release allows bypassing the issue.
The text was updated successfully, but these errors were encountered: