.Net Core lastest SDK 已安装,但未找到

我想在 linux 上使用 .Net Core 并且有最新版本:


> sudo pacman -Qs dotnet

local/dotnet-host 2.1.0-1

    A generic driver for the .NET Core Command Line Interface

local/dotnet-runtime 2.1.0-1

    The .NET Core runtime

local/dotnet-sdk 2.1.300-1

    The .NET Core SDK

> dotnet --version

2.1.300

但是当我想运行我的示例应用程序(只是剃刀模板)时:


> dotnet run  

Using launch settings from /home/user/src/WebRepTrack/Properties/launchSettings.json...

It was not possible to find any compatible framework version

The specified framework 'Microsoft.AspNetCore.App', version '2.1.0' was not found.

  - Check application dependencies and target a framework version installed at:

      /opt/dotnet/

  - Installing .NET Core prerequisites might help resolve this problem:

      http://go.microsoft.com/fwlink/?LinkID=798306&clcid=0x409

  - The .NET Core framework and SDK can be installed from:

      https://aka.ms/dotnet-download

看着这个问题,问题是用户没有安装合适的 sdk/runtime 版本,但这不是我的问题的原因,不是吗?


编辑:在查看 github 上的 dotnet-core 存储库后,我意识到 MS 现在随包 aspnetcore-runtime-2.1.0 一起提供了 asp.net 核心支持(而在此之前,它随核心运行时一起提供)。ArchLinux 软件包dotnet-runtime 不包含此更改!有关更多详细信息,请参见此处:https :

//bugs.archlinux.org/task/58806


拉丁的传说
浏览 286回答 1
1回答
打开App,查看更多内容
随时随地看视频慕课网APP