See the EDIT section below for TL; DR.
I used the MSVS 2015 community and upgraded to MSVS 2017. I am developing a .NET Core console application. I am only talking here about my local development machine, in which MSVS is installed, and it has the .NET Core runtime and SDK installed.
Project.json files were used in MSVS 2015, and by default the build process created a .dll file in bin/Debug/netcoreapp1.1which it could be run using the command dotnet run. But there is an opportunity to make a small adjustment in the project.json file:
...
"Microsoft.NETCore.App": {
"version": "1.0.1",
"type": "platform"
},
...
->
...
"Microsoft.NETCore.App": {
"version": "1.0.1"
},
...
and adding a section runtimeslike
"runtimes": {
"win10-x64": {}
}
, EXE , , dotnet run.
, , MSVS 2017 XML csproj? , ? , SDD, . , SDD, .
MSVS 2017, DLL . , hello world EXE . hello world csproj :
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp1.1</TargetFramework>
</PropertyGroup>
</Project>
DLL , dotnet run. :
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFrameworks>netcoreapp1.1;net46</TargetFrameworks>
</PropertyGroup>
</Project>
, - EXE . EXE , .NET Framework 4.6, .NET Core. , . , , .NET Core . ?
EDIT: , , , IDE. , Ctrl+Alt+F7 IDE, ,
dotnet build --configuration Debug
, ,
dotnet build --configuration Debug --runtime win10-x64
IDE , --runtime win10-x64.