node.js npm权限问题try running this command again as root/Administrator.
2016-02-24 18:58 youxin 阅读(1003) 评论(0) 编辑 收藏 举报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%\npm-cache
, or if you’re using PowerShell, $env:APPDATA\npm-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恢复正常。
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 基于Microsoft.Extensions.AI核心库实现RAG应用
· Linux系列:如何用heaptrack跟踪.NET程序的非托管内存泄露
· 开发者必知的日志记录最佳实践
· SQL Server 2025 AI相关能力初探
· Linux系列:如何用 C#调用 C方法造成内存泄露
· 无需6万激活码!GitHub神秘组织3小时极速复刻Manus,手把手教你使用OpenManus搭建本
· Manus爆火,是硬核还是营销?
· 终于写完轮子一部分:tcp代理 了,记录一下
· 别再用vector<bool>了!Google高级工程师:这可能是STL最大的设计失误
· 单元测试从入门到精通
2014-02-24 TCP 协议
2014-02-24 tcp抓包 Wireshark 使用
2014-02-24 (转)linux中常用的头文件
2014-02-24 ubuntu安装使用kdevelop
2013-02-24 jquery ajax loading效果
2013-02-24 jquery ajax基本操作
2013-02-24 php中count 多维数组长度统计实现方法