c# have all in one exe code example Example: compile in one single exe c# dotnet publish -r win-x64 -c Release /p:PublishSingleFile=true