微软将.NET Core on Linux打包为Ubuntu版本。我目前正在使用它。现在我想安装Json.NET,它告诉我要使用Package Manager console并运行以下命令:
PM> Install-Package Newtonsoft.Json
我想知道如何在Linux上执行此操作。我看到有一个Nuget CLI,但似乎在.NET Core上不可用。此外,文档说:
我应该如何在Linux上简单地安装一个软件包?与npm/cpan/pip/gem相对应的是什么.NET工具?在Mac和Linux上,安装Mono 4.4.2或更高版本。
当我运行
dotnet nuget
时,install
命令似乎已经丢失了。NuGet Command Line 4.3.0.5
Usage: dotnet nuget [options] [command]
Options:
-h|--help Show help information
--version Show version information
-v|--verbosity <verbosity> The verbosity of logging to use. Allowed values: Debug, Verbose, Information, Minimal, Warning, Error.
Commands:
delete Deletes a package from the server.
locals Clears or lists local NuGet resources such as http requests cache, packages cache or machine-wide global packages folder.
push Pushes a package to the server and publishes it.
Use "dotnet nuget [command] --help" for more information about a command.
npm install
,cpanm --install
,pip install
,gem install
。微软...“添加项目引用”。 - Evan Carroll