使用git cz 时报模块找不到 使用commitizen init cz-conventional-changelog --save --save-exact --force 又报下面错 头晕
Attempting to initialize using the npm package cz-conventional-changelog
npm WARN using --force Recommended protections disabled.
npm ERR! code EPERM
npm ERR! syscall mkdir
npm ERR! path D:\npm18\node_modules\.commitizen-CiP8enB1
npm ERR! errno -4048
npm ERR! Error: EPERM: operation not permitted, mkdir 'D:\npm18\node_modules\.commitizen-CiP8enB1'
npm ERR! [Error: EPERM: operation not permitted, mkdir 'D:\npm18\node_modules\.commitizen-CiP8enB1'] {
npm ERR! errno: -4048,
npm ERR! code: 'EPERM',
npm ERR! syscall: 'mkdir',
npm ERR! path: 'D:\\npm18\\node_modules\\.commitizen-CiP8enB1'
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.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\HF034\AppData\Local\npm-cache\_logs\2023-02-27T09_24_41_721Z-debug-0.log
Error: Command failed: npm install cz-conventional-changelog --save-dev --force
npm WARN using --force Recommended protections disabled.
npm ERR! code EPERM
npm ERR! syscall mkdir
npm ERR! path D:\npm18\node_modules\.commitizen-CiP8enB1
npm ERR! errno -4048
npm ERR! Error: EPERM: operation not permitted, mkdir 'D:\npm18\node_modules\.commitizen-CiP8enB1'
npm ERR! [Error: EPERM: operation not permitted, mkdir 'D:\npm18\node_modules\.commitizen-CiP8enB1'] {
npm ERR! errno: -4048,
npm ERR! code: 'EPERM',
npm ERR! syscall: 'mkdir',
npm ERR! path: 'D:\\npm18\\node_modules\\.commitizen-CiP8enB1'
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.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\HF034\AppData\Local\npm-cache\_logs\2023-02-27T09_24_41_721Z-debug-0.log
at checkExecSyncError (node:child_process:885:11)
at Object.execSync (node:child_process:957:15)
at init (D:\npm18\node_modules\commitizen\dist\commitizen\init.js:1024:28)
at Object.bootstrap (D:\npm18\node_modules\commitizen\dist\cli\commitizen.js:30:30)
at Object.<anonymous> (D:\npm18\node_modules\commitizen\bin\commitizen.js:2:38)
at Module._compile (node:internal/modules/cjs/loader:1275:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1329:10)
at Module.load (node:internal/modules/cjs/loader:1133:32)
at Module._load (node:internal/modules/cjs/loader:972:12) {
status: 4294963248,
signal: null,