centos安装nuget

1 官方文档 dotnet 可代替nuget.exe

https://docs.microsoft.com/zh-cn/nuget/install-nuget-client-tools

低版本的nuget 缺少一些参数

2 安装mono

https://www.mono-project.com/download/stable/#download-lin-centos

有了mono 可以运行nuget.exe 可以把windows上的nuget.exe拷贝上去 直接运行

安装的版本可能不是最新

下载源码 https://download.mono-project.com/sources/mono/

解压 tar -xvf mono-6.6.0.161.tar.xz

进入解压目录 执行 ./autogen.sh && make -j8 && make install

3 解决mono 访问https的问题

https://github.com/duplicati/duplicati/wiki/SSL-TLS-support-in-Mono

sudo cert-sync /etc/pki/tls/certs/ca-bundle.crt

4 nuget 从配置文件增加包源

nuget sources  -configfile /projects/nuget/config/NuGet.Config 

猜你喜欢

转载自www.cnblogs.com/wolbo/p/12196187.html