简体   繁体   English

安装nest js cli

[英]Install nest js cli

The installation does not work.安装不起作用。 Why?为什么? I have node v.16.17.0 and Windows 10. Please, help me.. :)我有节点 v.16.17.0 和 Windows 10。请帮帮我.. :)

PS C:> npm install -g @nestjs/cli PS C:> npm install -g @nestjs/cli
npm ERR: code EPERM npm ERR: syscall mkdir npm ERR: path C,\Program Files\nodejs\node_modules@nestjs npm ERR: errno -4048 npm ERR! npm ERR: code EPERM npm ERR: syscall mkdir npm ERR: path C,\Program Files\nodejs\node_modules@nestjs npm ERR: errno -4048 npm ERR! Error: EPERM: operation not permitted, mkdir 'C:\Program Files\nodejs\node_modules@nestjs'错误:EPERM:不允许操作,mkdir 'C:\Program Files\nodejs\node_modules@nestjs'
npm ERR: [Error: EPERM, operation not permitted: mkdir 'C:\Program Files\nodejs\node_modules@nestjs'] { npm ERR, errno: -4048, npm ERR: code, 'EPERM': npm ERR: syscall. npm ERR: [Error: EPERM, operation not permitted: mkdir 'C:\Program Files\nodejs\node_modules@nestjs'] { npm ERR, errno: -4048, npm ERR: code, 'EPERM': npm ERR: syscall. 'mkdir', npm ERR. 'mkdir',npm 错误。 path, 'C,\Program Files\nodejs\node_modules\@nestjs' npm ERR.路径,'C,\Program Files\nodejs\node_modules\@nestjs' npm ERR。 } npm ERR! npm 错误! npm ERR! npm 错误! The operation was rejected by your operating system.该操作被您的操作系统拒绝。 npm ERR! npm 错误! It's possible that the file was already in use (by a text editor or antivirus), npm ERR!该文件可能已被使用(由文本编辑器或防病毒软件),npm ERR! or that you lack permissions to access it.或者您没有访问它的权限。 npm ERR! npm 错误! npm ERR! npm 错误! If you believe this might be a permissions issue, please double-check the npm ERR!如果您认为这可能是权限问题,请仔细检查 npm ERR! permissions of the file and its containing directories, or try running npm ERR!文件及其包含目录的权限,或尝试运行 npm ERR! the command again as root/Administrator.再次以 root/管理员身份执行该命令。

npm ERR: A complete log of this run can be found in: npm ERR. npm ERR:此运行的完整日志可在以下位置找到:npm ERR。 C:\Users\rober\AppData\Local\npm-cache_logs\2022-09-20T19_56_27_828Z-debug-0.log C:\Users\rober\AppData\Local\npm-cache_logs\2022-09-20T19_56_27_828Z-debug-0.log

You can try these command that helps to resolve the error during the next js installation steps:您可以在接下来的 js 安装步骤中尝试这些有助于解决错误的命令:

  1. npm cache clean --force npm 缓存清理 --force
  2. npm install -g npm@latest --force npm install -g npm@latest --force
  3. rm -rf node_modules && rm./package-lock.json && npm install Try to install your component once again. rm -rf node_modules && rm./package-lock.json && npm install 再次尝试安装您的组件。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM