How to Run .NET Core (dotnet) on Ubuntu 20.04 LTS Focal fossa – Guide

Canonical’s latest long-term support release of Ubuntu Linux is codenamed Focal Fossa 20.04 LTS. This release includes new features and bug fixes, and it is recommended for all Ubuntu users. For .NET Core developers, each new Ubuntu release usually means that whenever we need to update the .NET Core release, we need to change the location of our package manager to get the correct version.

The .NET Core framework is a free and open source software framework designed with Linux and macOS in mind. It is the cross-platform successor to the .NET Framework, available for Linux, macOS and Windows systems. The .NET Core Framework already provides scaffolding tools for startup projects. Microsoft has now updated the dedicated page titled “Ubuntu 20.04 Package Manager – Install .NET Core” with instructions on how to use the package manager to install .NET Core on Ubuntu 20.04.

Install .Net Core

To use the .NET Core SDK 3.1, you first need to download it. You can find the .NET Core SDK 3.1 file here. Once you have downloaded it, go to the Downloads folder and open it up. In my case, this is the Downloads folder.

dotnet copy SDK.dll Now open the SDK and import it into your project using the following command. dotnet import SDK

Configure .Net CLI

With .Net Core, you can run dotnet commands from your terminal. This makes it easier to get started with the platform, as well as making it more versatile for development and testing.

To make dotnet CLI commands available to all shells on your computer, you can use the following command: dotnet shell –global-options= “–no-restore-env” ..

To permanently add commands to your shell, you can edit your bash profile. This file resides in: ~/.bashrc.

export DOTNET= “C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin”

export PATH=$PATH:$HOME/dotnet

#!/bin/bash

This file is used to configure the Bash shell.

It contains settings for the shell, such as its language and command line options.

Final note

This guide will show you how to install and run .NET Core on Ubuntu 20.04 LTS using Focal fossa. If you have any questions about the guide, please feel free to ask us in the comments below or on our social media channels. Finally, if you enjoyed this article, please share it with your friends and followers! ..