zoukankan      html  css  js  c++  java
  • 使用nrm管理 npm 镜像仓库

    使用nrm管理 npm 镜像仓库

    一、简介

    nrm(npm registry manager )是npm的镜像源管理工具,有时候国外资源太慢,使用这个就可以快速地在 npm 源间切换

    .安装nrm

    在命令行执行命令,npm install -g nrm,全局安装nrm。

    三. 使用

    3.1执行命令nrm ls查看可选的源。

    注意:如果windows 提示nrm 不是内部命令,重新打开cmd 执行 npm install -g nrm

    nrm ls 

    *npm ---- https://registry.npmjs.org/

    cnpm --- http://r.cnpmjs.org/

    taobao - http://registry.npm.taobao.org/

    eu ----- http://registry.npmjs.eu/

    au ----- http://registry.npmjs.org.au/

    sl ----- http://npm.strongloop.com/

    nj ----- https://registry.nodejitsu.com/

    其中,带*的是当前使用的源

    3.2执行命令nrm use nrm ls 显示的镜像

    例如:切换淘宝镜像 nrm use taobao

    3.3执行命令 nrm add <registry> <url>,其中reigstry为源名,url为源的路径。

    添加其他镜像

    nrm add 镜像名 镜像源地址

    3.4执行命令nrm del <registry>删除对应的源。

    3.5 nrm test 测试相应源的响应时间。

    nrm test npm  测试 npm 镜像的速度

     

  • 相关阅读:
    sobel
    构造函数
    #pragma once & ifnde
    #pragma comment
    SET容器
    重载[] int& operator[ ]( )
    仿函数 operator()()
    remove_if erase
    vector
    map
  • 原文地址:https://www.cnblogs.com/kali5k/p/13141108.html
Copyright © 2011-2022 走看看