.NET Core SDK Upgrade

I have been experimenting with .NET Core for a while now and I have also been trying to keep my .NET Core SDK versions up to date. I noticed though there is not much direction from Microsoft about how to upgrade the SDK version. I could not see any information about whether one should uninstall the previous version or overwrite the existing with the new SDK. So I am posting my findings around updating the .NET Core SDK.

Existing SDK Version

Finding the current version of your installed .NET Core SDK is simple:

  1. Launch the Command Prompt by typing Command Prompt into the search box on the menu bar and clicking the app returned.
  2. Alternatively, you can also type Windows Key + R to open the Run command dialog. Type cmd and hit the Enter key.
  3. In the Command Prompt window, type dotnet –version (using two hyphens before version) and hit the Enter key.
  4. The SDK version number is returned.

SDK01

You can see an earlier version of the .NET Core SDK is installed.

Upgrading The SDK

Recent SDKs and Binaries are on the .NET Core Download page. On this site, you can get both the Long Term Support (LTS) and Current versions of the SDK. The trade-off between the two is stability versus new features.

SDK02

The LTS version releases are supported for three years and are recommended if you want to stay on the same version for a long period. As of this writing, the LTS version available is NET Core 1.0.3.

The Current version releases include the latest features and are supported for three months after the next release. Staying up to date on the latest version should be a priority. As of this writing, the Current version available is .NET Core 1.1.

Since I want long-term support for my work, I am going with the LTS version. Select the correct 32-bit (x86) or 64-bit version for your operating system. I chose the 64-bit version and so I downloaded the file dotnet-dev-win-x64.1.0.0-preview2-003156.exe If you notice in the top image above, the version returned is 003131 so we know this downloaded version supersedes it. If we had opted for the Current version instead, we would have downloaded dotnet-dev-win-x64.1.0.0-preview2-1-003177.exe

Installing The SDK

Find the new SDK exe in your downloads folder and double-click it to start the install process. The Setup dialog box appears. Agree to the terms and click Install using the Setup Wizard to add the newest version of the SDK to your machine.

Once the SDK has been installed, return to the Command Prompt. Run the version command again by hitting the up arrow and the Enter key. The installed version returned should now match the SDK version downloaded.

SDK03

The current and previously installed versions of the .NET Core SDK can typically be found on your machine at C:\Program Files\dotnet\sdk You can see I have installed earlier versions of .NET Core which exists side by side.

SDK04

Summary

This article has shown you how to upgrade the .NET Core SDK version. Doing an in-place upgrade versus removing the previous version is supported with no side effects.

Advertisements

About Ken Cenerelli
I am a Programmer Writer, .NET Developer, Microsoft MVP - Visual Studio and Development Technologies, Public Speaker, Blogger, and Microsoft Azure Nerd. I blog regularly at kencenerelli.wordpress.com and can be found on Twitter via @KenCenerelli.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: