完整报错如下:
C:\Windows\system32>npm install cnpm -g
npm WARN rollback Rolling back minipass@3.3.6 failed (this is probably harmless): EPERM: operation not permitted, lstat 'C:\Users\QGLiu\AppData\Roaming\npm\node_modules\cnpm\node_modules\minipass-fetch\node_modules'
npm WARN notsup Unsupported engine for cnpm@9.4.0: wanted: {"node":">= 14.18.0"} (current: {"node":"14.3.0","npm":"6.14.5"})
npm WARN notsup Not compatible with your version of node/npm: cnpm@9.4.0
npm ERR! code EPERM
npm ERR! syscall rename
npm ERR! path C:\Users\QGLiu\AppData\Roaming\npm\node_modules\cnpm\node_modules\.make-fetch-happen.DELETE\node_modules\@npmcli
npm ERR! dest C:\Users\QGLiu\AppData\Roaming\npm\node_modules\cnpm\node_modules\make-fetch-happen\node_modules\@npmcli
npm ERR! errno -4048
npm ERR! Error: EPERM: operation not permitted, rename 'C:\Users\QGLiu\AppData\Roaming\npm\node_modules\cnpm\node_modules\.make-fetch-happen.DELETE\