收到 npm 安装错误 angular

getting npm install errors angular

我在另一台具有相同节点版本 (10.15.0) 的 PC 上安装节点模块时遇到一些错误。

哪里出错了?我已经删除了 node_modules 文件夹和 package-lock.json 文件,然后删除了 运行 npm install 命令,但这没有帮助。

C:\node\inventory_app_web>npm install
npm WARN deprecated @angular/http@7.0.4: Switch to @angular/common/http - see https://angular.io/guide/http
npm WARN deprecated core-js@2.5.7: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
npm WARN deprecated core-js@2.6.11: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
npm WARN deprecated istanbul@0.4.5: This module is no longer maintained, try this instead:
npm WARN deprecated   npm i nyc
npm WARN deprecated Visit https://istanbul.js.org/integrations for other alternatives.
npm WARN deprecated circular-json@0.5.9: CircularJSON is in maintenance only, flatted is its successor.
npm ERR! code ENOENT
npm ERR! syscall spawn git
npm ERR! path git
npm ERR! errno ENOENT
npm ERR! enoent Error while executing:
npm ERR! enoent undefined ls-remote -h -t ssh://git@github.com/eligrey/FileSaver.js.git
npm ERR! enoent
npm ERR! enoent
npm ERR! enoent spawn git ENOENT
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Sohail Ahmad\AppData\Roaming\npm-cache\_logs20-01-02T18_09_24_498Z-debug.log

我的错误,我安装了 Git,但它只能从 Git Bash 访问。使用第二个选项重新安装它并解决了我的问题: