#c# #linux #monodevelop #linux-mint
Вопрос:
Когда я пытаюсь сделать проект, я получаю:
Getting restore information for project /home/user/Projects/myApp/myApp/myApp.csproj
/usr/share/dotnet/sdk/5.0.203/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.TargetFrameworkInference.targets(54,5) : error MSB4186: Invalid static method invocation syntax: "[MSBuild]::GetTargetFrameworkIdentifier('$(TargetFramework)')". Method '[MSBuild]::GetTargetFrameworkIdentifier' not found. The invocation of the static method must be in the form: $([FullTypeName]::Method()), for example, $([System.IO.Path]::Combine(`a`, `b`)). Check that all parameters are defined, of the correct type, and specified in the proper order.
Unable to create package spec for project. '/home/user/Projects/myApp/myApp/myApp.csproj'
И когда я пытаюсь скомпилировать, я получаю:
Error: NuGet packages need to be restored before compiling. The NuGet MSBuild targets, which are required for build, are missing. NuGet MSBuild targets are generated when restoring NuGet packages. (myApp)
Как я могу его скомпилировать? или что мне нужно сделать для этого этого пробега?
Комментарии:
1. github.com/dotdevelop/dotdevelop/issues/40 Невозможно, если у вас установлен .NET 5 SDK (
/usr/share/dotnet/sdk/5.0.203/
). Переключитесь на VSCode, пожалуйста.2. Вы хотите увидеть скриншот VSCode или как?