zoukankan      html  css  js  c++  java
  • node.js npm权限问题try running this command again as root/Administrator.

    npm install报错;

    try running this command again as root/Administrator.

    以管理员身份打开cmd

    开始菜单-》所有程序-》附件,找到cmd,然后右键,以管理员身份运行。

    看:http://blogs.msdn.com/b/matt-harrington/archive/2012/02/23/how-to-fix-node-js-npm-permission-problems.aspx

    It turns out that you don’t have to run the command again as Administrator, and doing so won’t fix the problem.  Try npm cache clean first.  If that doesn’t fix things, take a look in%APPDATA% pm-cache, or if you’re using PowerShell, $env:APPDATA pm-cache.  After cleaning the cache, you may still be left with remnants.  Manually remove everything in that directory, and try again.  This has always fixed things for me.

     一个回答:

    在MAC上安装webpack以及reactjs等其它组件时,安装太慢卡住不动,直接ctrl+c终止后,再npm install后出npm WARN unmet dependency错误,npm cache clean后也不行。

    解决方法是直接把当前的node_modules目录删除掉,重新npm install恢复正常。

  • 相关阅读:
    java面试题
    linux下的文件目录结构
    Linux的基础命令
    Linux系统的介绍
    逻辑思维题
    37-字符的全排列
    36-螺旋矩阵
    35-面试:如何找出字符串的字典序全排列的第N种
    34-数细线
    33-求极差
  • 原文地址:https://www.cnblogs.com/youxin/p/5213981.html
Copyright © 2011-2022 走看看