Last active
August 18, 2019 15:07
-
-
Save guitarrapc/372e3306a39444747fb1e87ca2c2244f to your computer and use it in GitHub Desktop.
Single Executable with csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
namespace SimpleSingleExecutable | |
{ | |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
Console.WriteLine("Hello World!"); | |
} | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<Project Sdk="Microsoft.NET.Sdk"> | |
<PropertyGroup> | |
<TargetFramework>netcoreapp3.0</TargetFramework> | |
<OutputType>Exe</OutputType> | |
<PublishSingleFile>true</PublishSingleFile> | |
<IncludeSymbolsInSingleFile>true</IncludeSymbolsInSingleFile> | |
</PropertyGroup> | |
<PropertyGroup Condition="'$(SelfContained)' == 'true'"> | |
<PublishTrimmed>true</PublishTrimmed> | |
</PropertyGroup> | |
</Project> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment