ubuntu配置华为软件源,npm源
修改ubuntu镜像
/etc/apt/sources.list
deb http://repo.huaweicloud.com/ubuntu/ bionic main restricted universe multiverse
deb-src http://repo.huaweicloud.com/ubuntu/ bionic main restricted universe multiverse
deb http://repo.huaweicloud.com/ubuntu/ bionic-updates main restricted universe multiverse
deb-src http://repo.huaweicloud.com/ubuntu/ bionic-updates main restricted universe multiverse
deb http://repo.huaweicloud.com/ubuntu/ bionic-backports main restricted universe multiverse
deb-src http://repo.huaweicloud.com/ubuntu/ bionic-backports main restricted universe multiverse
deb http://repo.huaweicloud.com/ubuntu/ bionic-security main restricted universe multiverse
deb-src http://repo.huaweicloud.com/ubuntu/ bionic-security main restricted universe multiverse
deb http://repo.huaweicloud.com/ubuntu/ bionic-proposed main restricted universe multiverse
deb-src http://repo.huaweicloud.com/ubuntu/ bionic-proposed main restricted universe multiverse
deb https://apt.kitware.com/ubuntu/ bionic mai
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
修改rpm源
npm的配置文件为用户根目录下的:~/.npmrc(Windows路径为:C:\Users<UserName>.npmrc),您可以点击此处直接下载配置文件,或者运行如下命令设置:
npm config set registry https://repo.huaweicloud.com/repository/npm/
npm cache clean -f
华为开源镜像站同时也提供了工具类加速镜像,可以通过如下的命令设置加速地址:
※ 设置nodejs工具的镜像地址
npm config set disturl https://repo.huaweicloud.com/nodejs
※ 设置Node-Sass的镜像地址
npm config set sass_binary_site https://repo.huaweicloud.com/node-sass
※ 设置浏览器引擎驱动镜像地址,如果需要安装Selenium,请点击此处
npm config set phantomjs_cdnurl https://repo.huaweicloud.com/phantomjs
npm config set chromedriver_cdnurl https://repo.huaweicloud.com/chromedriver
npm config set operadriver_cdnurl https://repo.huaweicloud.com/operadriver
※ 设置Electron和Python的镜像地址
npm config set electron_mirror https://repo.huaweicloud.com/electron/
npm config set python_mirror https://repo.huaweicloud.com/python
文章来源: blog.csdn.net,作者:irrationality,版权归原作者所有,如需转载,请联系作者。
原文链接:blog.csdn.net/weixin_54227557/article/details/126201993
- 点赞
- 收藏
- 关注作者
评论(0)