react-native nrm -- NPM registry 管理工具-快速的切换源-转载

最近才看到的文章,3年前的,转过来或许有用。

这个包可以快速的切换源,非常方便,不用再配置命令了,竟然是三年以前就有的东西。

安装

$ npm install -g nrm

列出源的命令

$ nrm ls

  • npm ---- https://registry.npmjs.org/
    cnpm --- http://r.cnpmjs.org/
    eu ----- http://registry.npmjs.eu/
    au ----- http://registry.npmjs.org.au/
    sl ----- http://npm.strongloop.com/
    nj ----- https://registry.nodejitsu.com/

    上面好像少了taobao的源,现在taobao有单独的源了。

启用源或切换源

$ nrm use cnpm //switch registry to cnpm
Registry has been set to: http://r.cnpmjs.org/

还想继续看么?完了,就这么简单

cnodejs.org的链接地址

你可能感兴趣的:(react-native nrm -- NPM registry 管理工具-快速的切换源-转载)