Node.js/npm/源:修订间差异
来自康健生活
创建页面,内容为“== 标题文本 == == 源地址 == {| class="wikitable" |- | 官方 || https://registry.npmjs.org/ |- | 淘宝 || https://registry.npm.taobao.org |- | 阿里云 || https://npm.aliyun.com/ |- | 腾讯云 || https://mirrors.cloud.tencent.com/npm/ |- | 华为云 || https://mirrors.huaweicloud.com/repository/npm/ |- | 网易 || https://mirrors.163.com/npm/ |- | 中国科学技术大学 || http://mirrors.ustc.edu.cn/ |- | 清华大学 || https://mirrors.tuna.tsinghu…” |
|||
| 第22行: | 第22行: | ||
== 工具 == | == 工具 == | ||
=== registry === | === registry === | ||
{{Shc_out|<syntaxhighlight lang="bash"> | |||
npm config get registry</syntaxhighlight>|<syntaxhighlight lang="bash"> | |||
http://registry.npm.qiwoo.org/ | |||
</syntaxhighlight>|$|/home/kangkk}} | |||
设置 registry。 | |||
{{shc|<syntaxhighlight lang="bash"> | |||
# npm config set @myco:registry http://reg.example.com | |||
npm config set registry https://registry.npm.taobao.org</syntaxhighlight>|$|/home/kangkk}} | |||
进行分开测试 | |||
{{shc|<syntaxhighlight lang="bash"> | {{shc|<syntaxhighlight lang="bash"> | ||
npm config set registry | npm config set @q:registry http://registry.npm.qiwoo.org | ||
npm install --registry=https://registry.npmmirror.com</syntaxhighlight>|$|/home/kangkk}} | |||
=== nrm === | === nrm === | ||
2025年7月18日 (五) 19:36的版本
标题文本
源地址
工具
registry
[jian@kang /home/kangkk]$
npm config get registry
http://registry.npm.qiwoo.org/
设置 registry。
/home/kangkk
# npm config set @myco:registry http://reg.example.com
npm config set registry https://registry.npm.taobao.org
进行分开测试
/home/kangkk
npm config set @q:registry http://registry.npm.qiwoo.org
npm install --registry=https://registry.npmmirror.com
nrm
npm i -g nrm
kangjian@kangkk:~/github/kangkk.github.io$
nrm ls
* npm -------- https://registry.npmjs.org/
yarn ------- https://registry.yarnpkg.com/
cnpm ------- http://r.cnpmjs.org/
taobao ----- https://registry.npm.taobao.org/
nj --------- https://registry.nodejitsu.com/
npmMirror -- https://skimdb.npmjs.com/registry/
edunpm ----- http://registry.enpmjs.org/
kangjian@kangkk:~/github/kangkk.github.io$
nrm use taobao
Registry has been set to: https://registry.npm.taobao.org/
add
[jian@kang /home/kangkk]$
nrm add company http://registry.npm.qiwoo.org
add registry company success
No categories