为什么当我安装yo(用于VSC扩展)时会出现错误



我运行这个命令npm install -g yo generator-code来创建一个新的VSC扩展

错误:

$ npm install -g yo generator-code
npm WARN npm npm does not support Node.js v15.3.0
npm WARN npm You should probably upgrade to a newer version of node as we
npm WARN npm can't make any promises that npm will work with this version.
npm WARN npm You can find the latest version at https://nodejs.org/
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE   package: '@npmcli/arborist@4.0.4',
npm WARN EBADENGINE   required: { node: '^12.13.0 || ^14.15.0 || >=16' },
npm WARN EBADENGINE   current: { node: 'v15.3.0', npm: '8.1.3' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE   package: 'pacote@12.0.2',
npm WARN EBADENGINE   required: { node: '^12.13.0 || ^14.15.0 || >=16' },
npm WARN EBADENGINE   current: { node: 'v15.3.0', npm: '8.1.3' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE   package: '@npmcli/map-workspaces@2.0.0',
npm WARN EBADENGINE   required: { node: '^12.13.0 || ^14.15.0 || >=16' },
npm WARN EBADENGINE   current: { node: 'v15.3.0', npm: '8.1.3' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE   package: '@npmcli/metavuln-calculator@2.0.0',
npm WARN EBADENGINE   required: { node: '^12.13.0 || ^14.15.0 || >=16' },
npm WARN EBADENGINE   current: { node: 'v15.3.0', npm: '8.1.3' }
npm WARN EBADENGINE }
npm notice Beginning October 4, 2021, all connections to the npm registry - including for package installation - must use TLS 1.2 or higher. You are currently using plaintext http to connect. Please visit the GitHub blog for more information: https://github.blog/2021-08-23-npm-registry-deprecating-tls-1-0-tls-1-1/
npm notice Beginning October 4, 2021, all connections to the npm registry - including for package installation - must use TLS 1.2 or higher. You are currently using plaintext http to connect. Please visit the GitHub blog for more information: https://github.blog/2021-08-23-npm-registry-deprecating-tls-1-0-tls-1-1/
npm WARN deprecated har-validator@5.1.5: this library is no longer supported
npm WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm ERR! code ENOENT
npm ERR! syscall spawn C:Program Files (x86)gitbinbash.exe
npm ERR! path C:UsersARTURALAnpmnode_modulesyo
npm ERR! errno -4058
npm ERR! enoent spawn C:Program Files (x86)gitbinbash.exe 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:UsersARTURALAscooppersistnodejscache_logs2021-11-12T12_51_46_321Z-debug.log

npm版本:8.1.3

节点版本:v15.3.0

更新节点版本,位于https://nodejs.org/或:

npm i node

相关内容

  • 没有找到相关文章

最新更新