goland中npm无法使用的问题及解决
目录
- goland中npm无法使用
- npm ERR!无法安装任何包的解决
- 总结
goland中npm无法使用
明明已经成功安装且配置了环境到Windows上,而且goland上的配置也丝毫无错,但是就是不能使用npm,让人苦恼,如果你也遇到了这样的问题,希望这篇文章可以帮到你。
出现的错误代码是这样的
PS C:\Users\Lenovo\GolandProjects\shop_client1> npm install
npm WARN logfile could not be crphpeated: Error: EPERM: operation not permitted, open 'D:\AAA\nodejs\node_cache\_logs\2022-04-19T11_00_18_499Z-debug-0.log'npm ERR! code EPERMnpm ERR! syscall mkdirnpm ERR! path D:\AAA\nodejs\node_cache\_cacache\index-v5\7b\bfnpm ERR! errno -4048nphttp://www.devze.comm Ewww.devze.comRR! Error: EPERM: operation not permitted, mkdir 'D:\AAA\nodejs\node_cache\_cacache\index-v5\7b\bf'npm ERR! [Error: EPERM: operation not permitted, mkdir 'D:\AAA\nodejs\node_cache\_cacache\index-v5\7b\bf'] { npm ERR! errno: -4048,npm ERR! code: 'EPERM',npm ERR! syscall: 'mkdir',npm ERR! path: 'D:\\AAA\\nodejs\\node_cache\\_cacache\\index-v5\\7b\\bf'npm ERR! }npm ERR!npm ERR! The operation was rejected by your operating system.npm ERR! It's possible that the file was already in use (by a text editor or antivirus),npm ERR! or that y开发者_Python开发ou lack permissions to Access it.npm ERR!npm ERR! If you believe this might be a permissions issue, please double-check thenpm ERR! permissions of the file and its containing directories, or try runningnpm ERR! the command again as root/Administrator.npm ERR! Log files were not written due to an error writing to the directory: D:\AAA\nodejs\node_cache\_logsnpm ERR! You can reru编程客栈n the command with `--loglevel=verbose` to see the logs in your terminal
.npmrc
文件,就是npm
的配置文件所在位置。
当然,寻找这个文件的目的,多数是为了修改.npmrc
文件内容。
但npm
提供了方便快捷的修改方式,不知道这个文件的位置,其实也是可以修改的。
于是,配置之间就产生了冲突,找到他删掉它就可以了
默认位置是在 C:\Users\Lenovo 它是隐藏的
之后就可以继续我们的项目了,拜拜
logfile could not be created: Error: EPERM: operation not pejavascriptrmitted, open 'D:\AAA\nodejs\node_cache\_logs\2022-04-19T11_02_14_336Z-debug-0.log'
[..................] | : WARN logfile could not be created: Error: EPERM: operation not permitted, open 'D:\AAA\node > mintshop-client@1.0.0 dev> webpack-dev-server --inline --progress --config build/webpack.dev.conf.js
npm ERR!无法安装任何包的解决
npm config set proxy false npm cache clean
总结
以上为个人经验,希望能给大家一个参考,也希望大家多多支持我们。
精彩评论