学习vue数字大屏加载动漫效果时,在项目终端页面输入全局下载指令
npm install -g json-server
会报如下错误 operation not permitted……errno: -4048code:’EPERM’syscall: ‘mkdir‘……The operation was reiected by your operating systemIt‘s possible that the file was already in use (by a text editor or antivirus).on that vou lack permissions to access it.
…This is a problem related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settings.
npm ERR! network
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network ‘proxy‘ config is set properly. See: ‘npm help config‘…
一开始以为是权限问题,本人根据提示路径找到node_modules文件,将文件权限勾选完全控制
1)找到 C:Users{账户}下的.npmrc 文件,删除.npmrc 文件
2)输入npm cache clean —force 指令清除npm缓存:
npm cache clean --force
在使用npm cache clean –force 指令, 若反馈错误,可能是版本过高,可以输入:
npm cache verify
本人在刚刚删除.npmrc的目录下空白地方打开终端, 输入npm cache verify指令通过了:
2、解决报ERR_SOCKET_TIMEOUT错误问题参考链接2
经过以上步骤,当本人再次在项目终端页面输入全局下载指令时,会卡在idealTree: timing idealTree Completed in 32944ms不动,最终报以下错误:
npm config set registry
三、参考链接
1、npm-install 命令报错 -4048解决方案https://blog.csdn.net/weixin_44129867/article/details/126508964
2、npm install 卡在idealTree: timing idealTree Completed in 32944ms不动https://blog.csdn.net/weixin_48071078/article/details/132095789
原文地址:https://blog.csdn.net/qq_42294095/article/details/133807195
本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。
如若转载,请注明出处:http://www.7code.cn/show_35764.html
如若内容造成侵权/违法违规/事实不符,请联系代码007邮箱:suwngjj01@126.com进行投诉反馈,一经查实,立即删除!