Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Lost in versions and tools: .NET Core, Core Tools, dotnet Core CLI,

Ok, as a new .net dev ecosystem, I'm kind of lost in Core tools, versions and so on.

Could someone explain me the difference between

  • Core Tools preview x for VS 2015 - See here
  • .NET Core / SDK or not (1.0, 1.0.1, 1.1) - See here
  • Core CLI SDK preview 2, 3, 4, 5 - See here

What are previews and how are they related with main version numbering?

The versionning of Core itself seems weird for newcomers

  • When you go on the download page: https://www.microsoft.com/net/download/core#/current/sdk
  • You can see that downloading the .NET Core 1.1 SDK - Installer gives you dotnet-dev-win-x64.1.0.0-preview2-1-003177.exe:
    • 1.0.0 ??
  • On the same page, you can download *Visual Studio 2015 Tools (Preview 2) * which gives you DotNetCore.1.0.1-VS2015Tools.Preview2.0.3:
    • 1.0.1 ?

On the dotnet core github repository, we can see on there are some tools available in various versions:

1.0.3 released 12/13/2016

1.1 released 11/16/2016

1.1.0 Preview 1 released 10/24/2016

1.0.2 released 10/17/2016

1.0.1 released 9/13/2016

1.0.0 released 6/27/2016 RC2 released 5/16/2016 RC1 released 11/18/2015

On the dotnet CLI repo (I undestand it's building tools?), we can see they are talking about preview4, but in downloads links, everything is marked preview 5. AND they talk about downloading a .NET Core SDK Installer: is there the SDK core installer, so another version, or is it badly named and it's in fact the CLI only? Or does the SDK include the CLI, in which version then?

It gives you a dotnet-win-x64.latest.exe which seems to install .NET Core 1.0.1 Preview 5...

Finally on Azure, a Web app console will give you:

dotnet --version D:\home\site\wwwroot 1.0.0-preview3-004056 

WAOOOW: kind of lost...

What are the proper tools, in what correct version to start a new project with and have it properly deployable on Azure?

like image 444
BlackHoleGalaxy Avatar asked Dec 24 '16 16:12

BlackHoleGalaxy


People also ask

What is Dot Net core CLI?

The . NET command-line interface (CLI) is a cross-platform toolchain for developing, building, running, and publishing . NET applications.


1 Answers

You are confusing a few concepts here. Just because a version is released later, it do not mean it has more features. .NET Core 1.0 ist an LTS release and will be supplied with updates for 2 or 3 years iirc.

So even after 1.1 gets released, there will be maintenance for 1.0 which fix bugs or security issues. This has always been the case in Software development, look at Java. When Java 1.8 got released, there were still updates for Java 1.7.

The .NET Core SDK contains the dotnet cli tools, used to restore the packages, build, deploy and run .NET Core applications and it also contains the .NET Core runtime, which provides the framework DLLs (like .NET Framework 4.x setup) which you need to run portable apps.

The .NET Core runtime/SDK are independent of the CLI tools and can also be obtained via nuget packages.

The .NET Core Tools for Visual Studio 2015/2017 are just a set of tools which allow Visual Studio add support to the new project types and build pipeline.

The .NET Core Tools for VS also contain the SDK/runtime.

What you need to run on Azure, depends on your needs and which kind of runtime is installed on the Azure App Service instances, as they usually lag a bit behind the regular releases.

i.e. if you create self-contained applications, which get deployed with the .NET Core runtime, then you can just use any version, as each application will have its own runtime which can run side-by-side.

If you want run portable applications (which ship w/o .NET Core framework libraries when deployed), then you need to have the correct runtime installed on Azure App Service (Azure blog usually posts when new runtimes become available).

All other depends on your development environment.

TL;DR: If you

  • use Visual Studio 2015: Install Visual Studio 2015 Tools (Preview 2) *
  • use Visual Studio 2017: Download Visual Studio 2017
  • don't use Visual Studio, but want to develop for/with .NET Core: Install .NET Core SDK
  • don't use Visual Studio, but want to run .NET Core Appl: Install .NET Core Runtime

or

  • .NET Core Runtime (1.0.x or 1.1.x): Just the runtime
  • dotnet-cli: Just build/deployment tools
  • .NET Core SDK: Runtime + dotnet-cli
  • .NET Core Tools for Visual Studio: Runtime + dotnet-cli + Visual Studio integration (and new project templates)

cli-tools and Visual Studio Tools are not finished yet, hence in preview. They should go RTM together with VS2017 and the new MSBuild based project structure (moving away from xproj to csproj files), but this do not effect the status of the runtime/SDK.

like image 66
Tseng Avatar answered Sep 28 '22 03:09

Tseng