.NET Core notes
author: Paul Kim
categories: dotnet
tags: dotnet
Install .NET Core runtimes or SDKs
Windows 10
- Go to https://dotnet.microsoft.com/download/visual-studio-sdks
- Download and install SDKs for Visual Studio
Ubuntu 18.04
- Register Microsoft Key and feed
wget -q https://packages.microsoft.com/config/ubuntu/18.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
sudo dpkg -i packages-microsoft-prod.deb
- Update product available for installation
sudo add-apt-repository universe
sudo apt-get install apt-transport-https
- Install .NET Core SDK
sudo apt update
apt-cache search dotnet
sudo apt install dotnet-dev-1.1.11
sudo apt install dotnet-dev-1.1.13
sudo apt install dotnet-sdk-2.1
sudo apt install dotnet-sdk-2.2
sudo apt install dotnet-sdk-3.0
- Install .NET Core Runtime
sudo apt update
apt-cache search dotnet
sudo apt install aspnetcore-runtime-2.1
sudo apt install aspnetcore-runtime-2.2
sudo apt install aspnetcore-runtime-3.0
- Check everything installed correctly
dotnet
dotnet --help
dotnet --info
dotnet --version
dotnet --list-sdks
dotnet --list-runtimes
dpkg note:
# install package
dpkg -i packages-microsoft-prod
# uninstall package except config file
dpkg -r packages-microsoft-prod
# uninstall package including config file
dpkg -P packages-microsoft-prod
# list installed packages with version and description
dpkg -l packages-microsoft-prod
Uninstall .NET Core runtimes or SDKs
How to remove the .NET Core Runtime and SDK
Ubuntu 18.04
# uninstall script
curl -OL https://raw.githubusercontent.com/dotnet/cli/master/scripts/obtain/uninstall/dotnet-uninstall-debian-packages.sh
chmod u+x dotnet-uninstall-debian-packages.sh
sudo ./dotnet-uninstall-debian-packages.sh
# remove remaining folders
sudo rm -rf /usr/share/dotnet
sudo rm -rf ~/.dotnet
# uninstall package including config file
dpkg -P packages-microsoft-prod
sudo apt update
macOS
# uninstall script
curl -OL https://raw.githubusercontent.com/dotnet/cli/master/scripts/obtain/uninstall/dotnet-uninstall-pkgs.sh
chmod u+x dotnet-uninstall-pkgs.sh
sudo ./dotnet-uninstall-pkgs.sh
# remove remaining folders
sudo rm -rf /usr/share/dotnet
sudo rm -rf ~/.dotnet