详细报错

D:\workspace\es61> npm install -g cnpm --registry=https://registry.npm.taobao.org
npm WARN deprecated socks@1.1.10: If using 2.x branch, please upgrade to at least 2.1.6 to avoid a serious bug with socket data flow and an import issue introduced in 2.1.0
npm WARN tar ENOENT: no such file or directory, lstat 'C:\Users\Administrator\AppData\Roaming\npm\node_modules\.staging\npm-bb88aed9\node_modules\read-installed\test'
npm ERR! path C:\Users\Administrator\AppData\Roaming\npm\node_modules\.staging\npm-bb88aed9\node_modules\abbrev
npm ERR! code ENOENT
npm ERR! errno -4058
npm ERR! syscall rename
npm ERR! enoent ENOENT: no such file or directory, rename 'C:\Users\Administrator\AppData\Roaming\npm\node_modules\.staging\npm-bb88aed9\node_modules\abbrev' -> 'C:\Users\Administrator\AppData\Roaming\npm\node_modules\.staging\abbrev-99695b0f'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Administrator\AppData\Roaming\npm-cache\_logs\2019-02-24T14_16_24_548Z-debug.log
PS D:\workspace\es61> npm install -g cnpm --registry=https://registry.npm.taobao.org^C^C^C^C^C^C^C^C^C^C
npm ERR! Request path contains unescaped characters npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Administrator\AppData\Roaming\npm-cache\_logs\2019-02-24T14_18_17_575Z-debug.log
PS D:\workspace\es61> npm install -g cnpm@5.51 --registry=https://registry.npm.taobao.org
npm ERR! code ETARGET
npm ERR! notarget No matching version found for cnpm@5.51
npm ERR! notarget In most cases you or one of your dependencies are requesting
npm ERR! notarget a package version that doesn't exist. npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Administrator\AppData\Roaming\npm-cache\_logs\2019-02-24T14_21_13_999Z-debug.log
PS D:\workspace\es61> npm install -g cnpm@5.5.1 --registry=https://registry.npm.taobao.org
npm ERR! code ETARGET
npm ERR! notarget No matching version found for cnpm@5.5.1
npm ERR! notarget In most cases you or one of your dependencies are requesting
npm ERR! notarget a package version that doesn't exist. npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Administrator\AppData\Roaming\npm-cache\_logs\2019-02-24T14_21_24_209Z-debug.log

  解决

是因为cnpm 的安装版本需要 npm版本支持

1 cnpm -v 找到cnpm版本号

cnpm -v
cnpm@6.0.0 (C:\Users\Administrator\AppData\Roaming\npm\node_modules\cnpm\lib\parse_argv.js)
npm@6.8.0 (C:\Users\Administrator\AppData\Roaming\npm\node_modules\cnpm\node_modules\npm\lib\npm.js)
node@8.9.3 (D:\Program Files\tool\nodejs\node.exe)
npminstall@3.20.2 (C:\Users\Administrator\AppData\Roaming\npm\node_modules\cnpm\node_modules\npminstall\lib\index.js)
prefix=C:\Users\Administrator\AppData\Roaming\npm
win32 x64 10.0.14393
registry=https://registry.npm.taobao.org

2 使用命令安装npm

npm install npm@6.0.0

3 再次执行安装命令

npm install -g cnpm --registry=https://registry.npm.taobao.org

4 成功

npm 安装cnpm淘宝镜像时报错解决的更多相关文章

  1. npm安装cnpm淘宝镜像

      npm set registry https://registry.npm.taobao.org # 注册模块镜像 npm set disturl https://npm.taobao.org/d ...

  2. mac下安装cnpm淘宝镜像

    cnpm:官网 (事先已经安装了node,有npm)查看官网,提示安装需运行命令:npm install -g cnpm --registry=https://registry.npm.taobao. ...

  3. node npm 安装模块 淘宝镜像

    npm --registry https://registry.npm.taobao.org info underscore

  4. 为什么安装了淘宝镜像,永用cnpm安装依赖包会报错,而用npm就不会?报错:cnpm : 无法加载文件 C:\Users\93457\AppData\Roaming\npm\cnpm.ps1。。。。

    cnpm - 解决 " cnpm : 无法加载文件 C:\Users\93457\AppData\Roaming\npm\cnpm.ps1,因为在此系统上禁止运行脚本.有关详细信息 ... ...

  5. npm安装删除模块以及cnpm淘宝镜像

    npm安装模块 [$ npm install xxx]利用 npm 安装xxx模块到当前命令行所在目录: [$ npm install -g xxx]利用npm安装全局模块xxx: npm 删除模块 ...

  6. npm更换成淘宝镜像源以及cnpm

    1.需求由来 由于node安装插件是从国外服务器下载,受网络影响大,速度慢且可能出现异常.所以如果npm的服务器在中国就好了,所以我们乐于分享的淘宝团队(阿里巴巴旗下业务阿里云)干了这事.来自官网:“ ...

  7. npm设置为淘宝镜像地址

    1. npm设置为淘宝镜像 $npm config set registry https://registry.npm.taobao.org 2. 检查一下 $npm config get regis ...

  8. npm切换到淘宝镜像

    1. npm简介 1.1.说明:npm(node package manager)nodejs的包管理器,用于node插件管理(包括安装.卸载.管理依赖等): 1.2.使用npm安装插件:命令提示符执 ...

  9. npm切换成淘宝镜像源

    0-前言 我们都知道node下载第三方依赖包是从国外服务器下载,不是速度奇慢就是下载异常,切换成国内的淘宝镜像源很有必要: 1-切换方法 $ npm config set registry https ...

随机推荐

  1. uboot2012(一)分析重定位

    目录 引入 环境配置 编译体验 入口查找 代码分析 board_init_f pie 内存分布分析 SP设置 board_init_f 重定位 代码段重定位实现 变量地址修改 参考 title: ub ...

  2. tensorflow Pipeline 之TextLineReader 和decode_csv多分割替代方案

    1.TextLineReader reader = tf.TextLineReader() key, value = reader.read(filename_queue) record_defaul ...

  3. 帕斯卡(pascal)命名法:

    帕斯卡(pascal)命名法: 与骆驼命名法类似.只不过骆驼命名法是首字母小写,而帕斯卡命名法是首字母大写 如:public void DisplayInfo(); string UserName; ...

  4. Linux之 proc文件系统

    用户态与内核态交互的接口之一,管理方式与普通文件相同每个节点的文件权限(读/写)决定其查看和配置权限大量LINUX系统参数和状态信息可通过proc节点查看或配置/proc/<pid>/:查 ...

  5. 《Unbroken》

    <Unbroken> 献给正在奋力向前的你 You can’t connect the dots looking forward, you can only connect them lo ...

  6. linux下安装kubectl

    查看所有版本: https://github.com/kubernetes/kubernetes/blob/master/CHANGELOG.md 下载指定版本: curl -O https://dl ...

  7. docker 容器网络基础

    ======================== docker缺省自带的网络 ======================== host 网络, This enables a container to ...

  8. 一次mysql主从加keepalived配置搭建及切换演示

    [需求] 根据需求需要搭建mysql主从架构数据库及加keepalived进行自动切换VIP [环境介绍]  系统环境:CentOS release 6.4 (Final) + Server vers ...

  9. content+animation实现loading效果

    <dot></dot> dot { display: inline-block; height: 1em; line-height: 1; vertical-align: -. ...

  10. sparkRDD相关操作

    RDD(弹性分布式数据集).RDD以分区中的每一行进行分布式计算.父子依赖关系. 一.RDD创建操作 1)数据集合 Val data=Array(1, 2, 3, 4, 5, 6, 7, 8, 9) ...