【问题标题】:how do I setup the dot net 6 sdk on my operating system如何在我的操作系统上设置 dot net 6 sdk
【发布时间】:2021-12-27 09:52:53
【问题描述】:

我已经在我的 ubuntu-mate 21.10 上下载了 dotnet6 sdk,它可以工作。 tar.gz 的内容是:

host
LICENSE.txt
metadata
packs
sdk
sdk-manifests
shared
templates
ThirdPartyNotices.txt

我在哪里以及如何将我的文件和文件夹移动到正确的目的地,以便它们可以在 PATH 中进行开发,并且在 PATH 中有运行时,以便我可以运行我编译的应用程序。没有得到runtime missing 错误

【问题讨论】:

  • 通常,您只需在 ubuntu 上运行 sudo apt install dotnet-sdk-6.0。无需手动提取 tar。

标签: c# .net linux


【解决方案1】:

首先你要this link 然后向下滚动到 21.10(如果您使用的是 21.10 版本)并使用 bash 运行这些命令:

wget https://packages.microsoft.com/config/ubuntu/21.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
sudo dpkg -i packages-microsoft-prod.deb
rm packages-microsoft-prod.deb
Note

The .NET 6 packages haven't yet been published for Ubuntu 21.10. 
The following wget command uses the Ubuntu 21.04 repository.
This article will be updated when the packages are available in the Ubuntu 21.10 repository.

然后向下滚动以安装 sdk 部分并复制并运行以下命令:

sudo apt-get update; \
  sudo apt-get install -y apt-transport-https && \
  sudo apt-get update && \
  sudo apt-get install -y aspnetcore-runtime-6.0

如果您只想要运行时,请改为运行以下命令:

sudo apt-get update; \
  sudo apt-get install -y apt-transport-https && \
  sudo apt-get update && \
  sudo apt-get install -y aspnetcore-runtime-6.0

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2010-11-17
    • 1970-01-01
    • 2021-12-26
    • 2023-03-02
    • 1970-01-01
    相关资源
    最近更新 更多