在我的项目中,我想做一个npm update
,但是我总是犯这样的错误:
npm ERR! code EPERM
npm ERR! syscall rename
npm ERR! path C:\Users\user\Desktop\SylviaTest\node_modules\bootswatch
npm ERR! dest C:\Users\user\Desktop\SylviaTest\node_modules\.bootswatch-9Qtq80Xi
npm ERR! errno -4048
npm ERR! Error: EPERM: operation not permitted, rename 'C:\Users\user\Desktop\SylviaTest\node_modules\bootswatch' -> 'C:\Users\user\Desktop\SylviaTest\node_modules\.bootswatch-9Qtq80Xi'
npm ERR! [Error: EPERM: operation not permitted, rename 'C:\Users\user\Desktop\SylviaTest\node_modules\bootswatch' -> 'C:\Users\user\Desktop\SylviaTest\node_modules\.bootswatch-9Qtq80Xi
'] {
npm ERR! errno: -4048,
npm ERR! code: 'EPERM',
npm ERR! syscall: 'rename',
npm ERR! path: 'C:\\Users\\user\\Desktop\\SylviaTest\\node_modules\\bootswatch',
npm ERR! dest: 'C:\\Users\\user\\Desktop\\SylviaTest\\node_modules\\.bootswatch-9Qtq80Xi'
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 you lack permissions to access it.
npm ERR!
npm ERR! If you believe this might be a permissions issue, please double-check the
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator.
我试过:
删除packages.lock
但总是这个错误..。有人能帮帮我吗?
发布于 2021-06-21 05:12:34
对于有此问题的其他任何人:确保没有任何打开的文件可能正在使用这些文件。
。
然后再试一次npm命令。
https://stackoverflow.com/questions/64570700
复制相似问题