sách gpt4 ai đã đi

visual-studio-cordova - 更新 Node 和 NPM VS Cordova 更新 5

In lại 作者:行者123 更新时间:2023-12-02 03:47:30 33 4
mua khóa gpt4 Nike

我刚刚下载了 VS Apache Cordova Tools Update 5,但遇到了 Node 和 NPM 的问题。我使用默认的空白 cordova 项目进行测试。

版本

如果我在 VS 项目中对 Node 和 NPM 运行 gulp 检查,我会得到:Node version = v0.10.31NPM version = 1.4.9。但是,我还安装了 Node version = v5.4.1NPM version = 3.3.6

câu hỏi

当我使用 Cordova CLI 5.3.3 发布时,出现以下错误 nhập mô tả hình ảnh ở đây当我将 Cordova CLI 更改为 5.4.1 时,出现以下错误: nhập mô tả hình ảnh ở đây

如果我更改“工具”>“选项”>“项目和解决方案”>“外部 Web 工具”并添加路径 C:\Program Files (x86)\nodejs,我会收到以下警告和 npm安装失败错误。

npm WARN deprecated npmconf@2.1.2: this package has been reintegrated into npm and is now out of date with respect to npm

khác

如果我选择使用全局安装版本,我会得到 5.2.0。 nhập mô tả hình ảnh ở đây

非常感谢任何帮助!

VS Cordova Tools 5 的下载位置和更新信息 http://microsoft.github.io/vstacoblog/2016/01/13/annoucing-update-5.html

----------------------------------------更新 1/15/2015 下午 4:50(美国东部时间)---------- ---------------

以下是使用 node-v5.4.1-x86.msi 和 NPM = 3.5 发布包含 node = 5.4.1 的空白 cordova 项目时的构建日志。 3使用package.json安装。

1>------ Build started: Project: BlankCordovaApp4, Configuration: Debug Android ------
1> Your environment has been set up for using Node.js 5.4.1 (ia32) and npm.
1> ------ Ensuring correct global installation of package from source package directory: C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 14.0\COMMON7\IDE\EXTENSIONS\APACHECORDOVATOOLS\packages\vs-tac
1> ------ Name from source package.json: vs-tac
1> ------ Version from source package.json: 1.0.28
1> ------ Package already installed globally at correct version.
1> ------ Installing Cordova tools cordova@5.4.1 for project from npm. This could take a few minutes...
1> Each package is licensed to you by its owner. Microsoft is not responsible for, nor does it grant any licenses to, third-party packages. Some packages may include dependencies which are governed by additional licenses. Follow the package source (feed) URL to determine any dependencies.
1> npm WARN deprecated npmconf@2.1.2: this package has been reintegrated into npm and is now out of date with respect to npm
1> npm ERR! Windows_NT 6.3.9600
1> npm ERR! argv "C:\\Program Files (x86)\\nodejs\\node.exe" "C:\\Users\\DBiele\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "install" "cordova@5.4.1" "--loglevel" "warn"
1> npm ERR! node v5.4.1
1> npm ERR! npm v3.3.6
1>
1> npm ERR! Cannot read property 'localeCompare' of undefined
1> npm ERR!
1>MDAVSCLI : npm ERR! If you need help, you may report this error at:
1> npm ERR!
1>
1> npm ERR! Please include the following file with any support request:
1> npm ERR! C:\Users\DBiele\AppData\Roaming\npm\node_modules\vs-tac\node_modules\cordova\5.4.1\npm-debug.log
1> [Error: ------ npm install failed. Exit code: 1]
1> C:\Users\DBiele\AppData\Roaming\npm\node_modules\vs-tac\node_modules\q\q.js:126
1> throw e;
1> ^
1>
1>MDAVSCLI : error : ------ npm install failed. Exit code: 1
1> at ChildProcess. (C:\Users\DBiele\AppData\Roaming\npm\node_modules\vs-tac\lib\util.js:655:29)
1> at emitTwo (events.js:87:13)
1> at ChildProcess.emit (events.js:172:7)
1> at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)

这是删除 NPM 3.5.3 ,清除 cordova 缓存npm 缓存清理后的另一个构建日志

1>------ Build started: Project: BlankCordovaApp4, Configuration: Debug Android ------
1> Your environment has been set up for using Node.js 5.4.1 (ia32) and npm.
1> ------ Ensuring correct global installation of package from source package directory: C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 14.0\COMMON7\IDE\EXTENSIONS\APACHECORDOVATOOLS\packages\vs-tac
1> ------ Name from source package.json: vs-tac
1> ------ Version from source package.json: 1.0.28
1> ------ Package not currently installed globally.
1> ------ Installing globally from source package. This could take a few minutes...
1> Each package is licensed to you by its owner. Microsoft is not responsible for, nor does it grant any licenses to, third-party packages. Some packages may include dependencies which are governed by additional licenses. Follow the package source (feed) URL to determine any dependencies.
1> npm WARN deprecated npmconf@0.1.16: this package has been reintegrated into npm and is now out of date with respect to npm
1> npm WARN engine npm@1.3.4: wanted: {"node":">=0.6","npm":"1"} (current: {"node":"5.4.1","npm":"3.3.6"})
1> C:\Users\DBiele\AppData\Roaming\npm\vs-tac-cli -> C:\Users\DBiele\AppData\Roaming\npm\node_modules\vs-tac\vs-tac-cli.cmd
1> > edge@4.0.0 install C:\Users\DBiele\AppData\Roaming\npm\node_modules\vs-tac\node_modules\edge
1> > node tools/install.js
1> ***************************************
1> [Error: The edge module has not been pre-compiled for node.js version v5.4.1. You must build a custom version of edge.node. Please refer to https://github.com/tjanczuk/edge for building instructions.]
1> ***************************************
1> Success: platform check for edge.js: node.js ia32 v5.4.1
1> C:\Users\DBiele\AppData\Roaming\npm
1> └─┬ vs-tac@1.0.28
1> ├── adm-zip@0.4.4
1> ├─┬ edge@4.0.0
1> │ ├── edge-cs@0.2.7
1> │ └── nan@2.2.0
1> ├─┬ elementtree@0.1.6
1> │ └── sax@0.3.5
1> ├─┬ fstream@0.1.28
1> │ ├── graceful-fs@3.0.8
1> │ └── inherits@2.0.1
1> ├── mkdirp@0.3.5
1> ├── ncp@0.5.1
1> ├─┬ optimist@0.6.1
1> │ ├── minimist@0.0.10
1> │ └── wordwrap@0.0.3
1> ├─┬ plugman@0.22.4
1> │ ├─┬ cordova-lib@0.21.6
1> │ │ ├── bplist-parser@0.0.5
1> │ │ ├─┬ cordova-js@3.6.2
1> │ │ │ ├─┬ browserify@3.46.0
1> │ │ │ │ ├─┬ assert@1.1.1
1> │ │ │ │ │ └── util@0.10.2
1> │ │ │ │ ├─┬ browser-pack@2.0.1
1> │ │ │ │ │ ├─┬ combine-source-map@0.3.0
1> │ │ │ │ │ │ ├── convert-source-map@0.3.4
1> │ │ │ │ │ │ ├── inline-source-map@0.3.0
1> │ │ │ │ │ │ └─┬ source-map@0.1.34
1> │ │ │ │ │ │ └── amdefine@0.1.0
1> │ │ │ │ │ └─┬ JSONStream@0.6.4
1> │ │ │ │ │ ├── jsonparse@0.0.5
1> │ │ │ │ │ └── through@2.2.7
1> │ │ │ │ ├── browser-resolve@1.2.4
1> │ │ │ │ ├─┬ browserify-zlib@0.1.4
1> │ │ │ │ │ └── pako@0.2.3
1> │ │ │ │ ├─┬ buffer@2.1.13
1> │ │ │ │ │ ├── base64-js@0.0.7
1> │ │ │ │ │ └── ieee754@1.1.3
1> │ │ │ │ ├── builtins@0.0.4
1> │ │ │ │ ├── commondir@0.0.1
1> │ │ │ │ ├─┬ concat-stream@1.4.6
1> │ │ │ │ │ ├─┬ readable-stream@1.1.13-1
1> │ │ │ │ │ │ ├── core-util-is@1.0.1
1> │ │ │ │ │ │ ├── isarray@0.0.1
1> │ │ │ │ │ │ └── string_decoder@0.10.25-1
1> │ │ │ │ │ └── typedarray@0.0.6
1> │ │ │ │ ├── console-browserify@1.0.3
1> │ │ │ │ ├── constants-browserify@0.0.1
1> │ │ │ │ ├── crypto-browserify@1.0.9
1> │ │ │ │ ├── deep-equal@0.1.2
1> │ │ │ │ ├── defined@0.0.0
1> │ │ │ │ ├─┬ deps-sort@0.1.2
1> │ │ │ │ │ ├─┬ JSONStream@0.6.4
1> │ │ │ │ │ │ ├── jsonparse@0.0.5
1> │ │ │ │ │ │ └── through@2.2.7
1> │ │ │ │ │ └── minimist@0.0.10
1> │ │ │ │ ├─┬ derequire@0.8.0
1> │ │ │ │ │ ├── esprima-fb@3001.1.0-dev-harmony-fb
1> │ │ │ │ │ ├─┬ esrefactor@0.1.0
1> │ │ │ │ │ │ ├── escope@0.0.16
1> │ │ │ │ │ │ ├── esprima@1.0.4
1> │ │ │ │ │ │ └── estraverse@0.0.4
1> │ │ │ │ │ └── estraverse@1.5.0
1> │ │ │ │ ├── domain-browser@1.1.2
1> │ │ │ │ ├── duplexer@0.1.1
1> │ │ │ │ ├── events@1.0.1
1> │ │ │ │ ├─┬ glob@3.2.11
1> │ │ │ │ │ └─┬ minimatch@0.3.0
1> │ │ │ │ │ ├── lru-cache@2.5.0
1> │ │ │ │ │ └── sigmund@1.0.0
1> │ │ │ │ ├─┬ http-browserify@1.3.2
1> │ │ │ │ │ └── Base64@0.2.1
1> │ │ │ │ ├── https-browserify@0.0.0
1> │ │ │ │ ├── inherits@2.0.1
1> │ │ │ │ ├─┬ insert-module-globals@5.0.1
1> │ │ │ │ │ ├─┬ lexical-scope@1.1.0
1> │ │ │ │ │ │ └─┬ astw@1.1.0
1> │ │ │ │ │ │ └── esprima-fb@3001.1.0-dev-harmony-fb
1> │ │ │ │ │ └── process@0.6.0
1> │ │ │ │ ├─┬ JSONStream@0.7.4
1> │ │ │ │ │ └── jsonparse@0.0.5
1> │ │ │ │ ├─┬ module-deps@1.10.0
1> │ │ │ │ │ ├─┬ detective@3.1.0
1> │ │ │ │ │ │ ├─┬ escodegen@1.1.0
1> │ │ │ │ │ │ │ ├── esprima@1.0.4
1> │ │ │ │ │ │ │ ├── estraverse@1.5.0
1> │ │ │ │ │ │ │ ├── esutils@1.0.0
1> │ │ │ │ │ │ │ └─┬ source-map@0.1.34
1> │ │ │ │ │ │ │ └── amdefine@0.1.0
1> │ │ │ │ │ │ └── esprima-fb@3001.1.0-dev-harmony-fb
1> │ │ │ │ │ └── minimist@0.0.10
1> │ │ │ │ ├── os-browserify@0.1.2
1> │ │ │ │ ├── parents@0.0.2
1> │ │ │ │ ├── path-browserify@0.0.0
1> │ │ │ │ ├── punycode@1.2.4
1> │ │ │ │ ├── querystring-es3@0.2.0
1> │ │ │ │ ├── resolve@0.6.3
1> │ │ │ │ ├── shallow-copy@0.0.1
1> │ │ │ │ ├── shell-quote@0.0.1
1> │ │ │ │ ├─┬ stream-browserify@0.1.3
1> │ │ │ │ │ └── process@0.5.2
1> │ │ │ │ ├── stream-combiner@0.0.4
1> │ │ │ │ ├── string_decoder@0.0.1
1> │ │ │ │ ├─┬ subarg@0.0.1
1> │ │ │ │ │ └── minimist@0.0.10
1> │ │ │ │ ├─┬ syntax-error@1.1.0
1> │ │ │ │ │ └── esprima-fb@3001.1.0-dev-harmony-fb
1> │ │ │ │ ├─┬ through2@0.4.2
1> │ │ │ │ │ ├─┬ readable-stream@1.0.27-1
1> │ │ │ │ │ │ ├── core-util-is@1.0.1
1> │ │ │ │ │ │ ├── isarray@0.0.1
1> │ │ │ │ │ │ └── string_decoder@0.10.25-1
1> │ │ │ │ │ └─┬ xtend@2.1.2
1> │ │ │ │ │ └── object-keys@0.4.0
1> │ │ │ │ ├─┬ timers-browserify@1.0.1
1> │ │ │ │ │ └── process@0.5.2
1> │ │ │ │ ├── tty-browserify@0.0.0
1> │ │ │ │ ├─┬ umd@2.0.0
1> │ │ │ │ │ ├─┬ rfile@1.0.0
1> │ │ │ │ │ │ ├── callsite@1.0.0
1> │ │ │ │ │ │ └── resolve@0.3.1
1> │ │ │ │ │ └─┬ ruglify@1.0.0
1> │ │ │ │ │ └─┬ uglify-js@2.2.5
1> │ │ │ │ │ ├─┬ optimist@0.3.7
1> │ │ │ │ │ │ └── wordwrap@0.0.2
1> │ │ │ │ │ └─┬ source-map@0.1.34
1> │ │ │ │ │ └── amdefine@0.1.0
1> │ │ │ │ ├── url@0.10.1
1> │ │ │ │ ├── util@0.10.3
1> │ │ │ │ └─┬ vm-browserify@0.0.4
1> │ │ │ │ └── indexof@0.0.1
1> │ │ │ ├── through@2.3.4
1> │ │ │ └─┬ uglify-js@2.4.14
1> │ │ │ ├── async@0.2.10
1> │ │ │ ├─┬ optimist@0.3.7
1> │ │ │ │ └── wordwrap@0.0.2
1> │ │ │ ├─┬ source-map@0.1.34
1> │ │ │ │ └── amdefine@0.1.0
1> │ │ │ └── uglify-to-browserify@1.0.2
1> │ │ ├─┬ dep-graph@1.1.0
1> │ │ │ └── underscore@1.2.1
1> │ │ ├─┬ elementtree@0.1.5
1> │ │ │ └── sax@0.3.5
1> │ │ ├─┬ glob@3.2.11
1> │ │ │ ├── inherits@2.0.1
1> │ │ │ └─┬ minimatch@0.3.0
1> │ │ │ ├── lru-cache@2.5.0
1> │ │ │ └── sigmund@1.0.0
1> │ │ ├── mime@1.2.11
1> │ │ ├─┬ npm@1.3.4
1> │ │ │ ├── ini@1.1.0
1> │ │ │ ├─┬ minimatch@0.2.12
1> │ │ │ │ └── sigmund@1.0.0
1> │ │ │ ├── mkdirp@0.3.5
1> │ │ │ ├── osenv@0.0.3
1> │ │ │ └─┬ request@2.21.0
1> │ │ │ ├── aws-sign@0.3.0
1> │ │ │ ├── cookie-jar@0.3.0
1> │ │ │ ├─┬ form-data@0.0.8
1> │ │ │ │ └─┬ combined-stream@0.0.4
1> │ │ │ │ └── delayed-stream@0.0.5
1> │ │ │ ├─┬ hawk@0.13.1
1> │ │ │ │ ├─┬ boom@0.4.2
1> │ │ │ │ │ └── hoek@0.9.1
1> │ │ │ │ ├── hoek@0.8.5
1> │ │ │ │ └─┬ sntp@0.2.4
1> │ │ │ │ └── hoek@0.9.1
1> │ │ │ ├─┬ http-signature@0.9.11
1> │ │ │ │ ├── asn1@0.1.11
1> │ │ │ │ ├── assert-plus@0.1.2
1> │ │ │ │ └── ctype@0.5.2
1> │ │ │ ├── json-stringify-safe@4.0.0
1> │ │ │ ├── oauth-sign@0.3.0
1> │ │ │ └── tunnel-agent@0.3.0
1> │ │ ├─┬ npmconf@0.1.16
1> │ │ │ ├─┬ config-chain@1.1.8
1> │ │ │ │ └── proto-list@1.2.3
1> │ │ │ ├── inherits@2.0.1
1> │ │ │ ├── ini@1.1.0
1> │ │ │ ├── mkdirp@0.3.5
1> │ │ │ ├─┬ nopt@2.2.1
1> │ │ │ │ └── abbrev@1.0.5
1> │ │ │ └── once@1.3.0
1> │ │ ├── osenv@0.0.3
1> │ │ ├─┬ plist-with-patches@0.5.1
1> │ │ │ ├── xmlbuilder@0.4.3
1> │ │ │ └── xmldom@0.1.19
1> │ │ ├── properties-parser@0.2.3
1> │ │ ├── q@0.9.7
1> │ │ ├─┬ rc@0.3.0
1> │ │ │ ├── deep-extend@0.2.10
1> │ │ │ ├── ini@1.1.0
1> │ │ │ └─┬ optimist@0.3.7
1> │ │ │ └── wordwrap@0.0.2
1> │ │ ├─┬ request@2.22.0
1> │ │ │ ├── aws-sign@0.3.0
1> │ │ │ ├── cookie-jar@0.3.0
1> │ │ │ ├── forever-agent@0.5.2
1> │ │ │ ├─┬ form-data@0.0.8
1> │ │ │ │ ├── async@0.2.10
1> │ │ │ │ └─┬ combined-stream@0.0.4
1> │ │ │ │ └── delayed-stream@0.0.5
1> │ │ │ ├─┬ hawk@0.13.1
1> │ │ │ │ ├─┬ boom@0.4.2
1> │ │ │ │ │ └── hoek@0.9.1
1> │ │ │ │ ├── cryptiles@0.2.2
1> │ │ │ │ ├── hoek@0.8.5
1> │ │ │ │ └─┬ sntp@0.2.4
1> │ │ │ │ └── hoek@0.9.1
1> │ │ │ ├─┬ http-signature@0.10.0
1> │ │ │ │ ├── asn1@0.1.11
1> │ │ │ │ ├── assert-plus@0.1.2
1> │ │ │ │ └── ctype@0.5.2
1> │ │ │ ├── json-stringify-safe@4.0.0
1> │ │ │ ├── node-uuid@1.4.1
1> │ │ │ ├── oauth-sign@0.3.0
1> │ │ │ ├── qs@0.6.6
1> │ │ │ └── tunnel-agent@0.3.0
1> │ │ ├── semver@2.0.11
1> │ │ ├── shelljs@0.1.4
1> │ │ ├─┬ tar@0.1.19
1> │ │ │ ├── block-stream@0.0.7
1> │ │ │ ├─┬ fstream@0.1.27
1> │ │ │ │ ├── graceful-fs@3.0.2
1> │ │ │ │ ├── mkdirp@0.3.5
1> │ │ │ │ └── rimraf@2.2.8
1> │ │ │ └── inherits@2.0.1
1> │ │ ├── underscore@1.4.4
1> │ │ └─┬ xcode@0.6.6
1> │ │ ├── node-uuid@1.3.3
1> │ │ └── pegjs@0.6.2
1> │ ├─┬ nopt@1.0.10
1> │ │ └── abbrev@1.0.7
1> │ ├─┬ npm@1.3.4
1> │ │ ├─┬ cmd-shim@1.1.0
1> │ │ │ └── graceful-fs@1.2.3
1> │ │ ├── ini@1.1.0
1> │ │ ├─┬ minimatch@0.2.12
1> │ │ │ └── sigmund@1.0.0
1> │ │ ├── mkdirp@0.3.5
1> │ │ ├── osenv@0.0.3
1> │ │ ├─┬ read-installed@0.2.2
1> │ │ │ └── graceful-fs@1.2.3
1> │ │ ├─┬ read-package-json@1.1.0
1> │ │ │ └── graceful-fs@1.2.3
1> │ │ ├─┬ request@2.21.0
1> │ │ │ ├── aws-sign@0.3.0
1> │ │ │ ├── cookie-jar@0.3.0
1> │ │ │ ├─┬ form-data@0.0.8
1> │ │ │ │ └─┬ combined-stream@0.0.4
1> │ │ │ │ └── delayed-stream@0.0.5
1> │ │ │ ├─┬ hawk@0.13.1
1> │ │ │ │ ├─┬ boom@0.4.2
1> │ │ │ │ │ └── hoek@0.9.1
1> │ │ │ │ ├── hoek@0.8.5
1> │ │ │ │ └─┬ sntp@0.2.4
1> │ │ │ │ └── hoek@0.9.1
1> │ │ │ ├─┬ http-signature@0.9.11
1> │ │ │ │ ├── asn1@0.1.11
1> │ │ │ │ ├── assert-plus@0.1.2
1> │ │ │ │ └── ctype@0.5.2
1> │ │ │ ├── json-stringify-safe@4.0.0
1> │ │ │ ├── oauth-sign@0.3.0
1> │ │ │ └── tunnel-agent@0.3.0
1> │ │ ├─┬ rimraf@2.2.0
1> │ │ │ └── graceful-fs@1.2.3
1> │ │ └─┬ sha@1.0.1
1> │ │ └── graceful-fs@1.2.3
1> │ ├── q@0.9.7
1> │ ├─┬ rc@0.3.0
1> │ │ ├── deep-extend@0.2.11
1> │ │ ├── ini@1.1.0
1> │ │ └── optimist@0.3.7
1> │ └── underscore@1.4.4
1> ├── q@1.0.1
1> ├─┬ request@2.36.0
1> │ ├── aws-sign2@0.5.0
1> │ ├── forever-agent@0.5.2
1> │ ├─┬ form-data@0.1.4
1> │ │ ├── async@0.9.2
1> │ │ └─┬ combined-stream@0.0.7
1> │ │ └── delayed-stream@0.0.5
1> │ ├─┬ hawk@1.0.0
1> │ │ ├── boom@0.4.2
1> │ │ ├── cryptiles@0.2.2
1> │ │ ├── hoek@0.9.1
1> │ │ └── sntp@0.2.4
1> │ ├─┬ http-signature@0.10.1
1> │ │ ├── asn1@0.1.11
1> │ │ ├── assert-plus@0.1.5
1> │ │ └── ctype@0.5.3
1> │ ├── json-stringify-safe@5.0.1
1> │ ├── mime@1.2.11
1> │ ├── node-uuid@1.4.7
1> │ ├── oauth-sign@0.3.0
1> │ ├── qs@0.6.6
1> │ ├── tough-cookie@2.2.1
1> │ └── tunnel-agent@0.4.2
1> ├── rimraf@2.2.6
1> ├─┬ ripple-emulator@0.9.32
1> │ ├── accounting@0.4.1
1> │ ├── colors@0.6.0-1
1> │ ├── connect-xcors@0.5.2
1> │ ├─┬ express@3.1.0
1> │ │ ├── buffer-crc32@0.1.1
1> │ │ ├── commander@0.6.1
1> │ │ ├─┬ connect@2.7.2
1> │ │ │ ├── bytes@0.1.0
1> │ │ │ ├── formidable@1.0.11
1> │ │ │ ├── pause@0.0.1
1> │ │ │ └── qs@0.5.1
1> │ │ ├── cookie@0.0.5
1> │ │ ├── cookie-signature@0.0.1
1> │ │ ├─┬ debug@2.2.0
1> │ │ │ └── ms@0.7.1
1> │ │ ├── fresh@0.1.0
1> │ │ ├── methods@0.0.1
1> │ │ ├── mkdirp@0.3.3
1> │ │ ├── range-parser@0.0.4
1> │ │ └─┬ send@0.1.0
1> │ │ └── mime@1.2.6
1> │ ├── moment@1.7.2
1> │ ├── open@0.0.3
1> │ └─┬ request@2.12.0
1> │ └─┬ form-data@0.0.3
1> │ └─┬ combined-stream@0.0.3
1> │ └── delayed-stream@0.0.5
1> ├── semver@2.3.1
1> └─┬ tar@0.1.20
1> └── block-stream@0.0.8
1> ------ npm install of vs-tac@1.0.28 from C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 14.0\COMMON7\IDE\EXTENSIONS\APACHECORDOVATOOLS\packages\vs-tac completed.
1> ------ Installing Cordova tools cordova@5.4.1 for project from npm. This could take a few minutes...
1> Each package is licensed to you by its owner. Microsoft is not responsible for, nor does it grant any licenses to, third-party packages. Some packages may include dependencies which are governed by additional licenses. Follow the package source (feed) URL to determine any dependencies.
1> npm WARN deprecated npmconf@2.1.2: this package has been reintegrated into npm and is now out of date with respect to npm
1> npm ERR! Windows_NT 6.3.9600
1> npm ERR! argv "C:\\Program Files (x86)\\nodejs\\node.exe" "C:\\Users\\DBiele\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "install" "cordova@5.4.1" "--loglevel" "warn"
1> npm ERR! node v5.4.1
1> npm ERR! npm v3.3.6
1>
1> npm ERR! Cannot read property 'localeCompare' of undefined
1> npm ERR!
1>MDAVSCLI : npm ERR! If you need help, you may report this error at:
1> npm ERR!
1>
1> npm ERR! Please include the following file with any support request:
1> npm ERR! C:\Users\DBiele\AppData\Roaming\npm\node_modules\vs-tac\node_modules\cordova\5.4.1\npm-debug.log
1> [Error: ------ npm install failed. Exit code: 1]
1> C:\Users\DBiele\AppData\Roaming\npm\node_modules\vs-tac\node_modules\q\q.js:126
1> throw e;
1> ^
1>
1>MDAVSCLI : error : ------ npm install failed. Exit code: 1
1> at ChildProcess. (C:\Users\DBiele\AppData\Roaming\npm\node_modules\vs-tac\lib\util.js:655:29)
1> at emitTwo (events.js:87:13)
1> at ChildProcess.emit (events.js:172:7)
1> at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
========== Deploy: 0 succeeded, 0 failed, 0 skipped ==========

========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
========== Deploy: 0 succeeded, 0 failed, 0 skipped ==========

当我使用 powershell 或 cmd 安装 cordova npm install -g cordova 时,出现以下错误

C:\Users\DBiele>npm install -g cordova
npm WARN deprecated npmconf@2.1.2: this package has been reintegrated into npm a
nd is now out of date with respect to npm
npm WARN install:isarray ENOENT: no such file or directory, rename 'C:\Users\DBi
ele\AppData\Roaming\npm\node_modules\cordova\node_modules\buffer\node_modules\is
array' -> 'C:\Users\DBiele\AppData\Roaming\npm\node_modules\cordova\node_modules
\buffer\node_modules\isarray'
npm WARN install:negotiator ENOENT: no such file or directory, rename 'C:\Users\
DBiele\AppData\Roaming\npm\node_modules\cordova\node_modules\express\node_module
s\negotiator' -> 'C:\Users\DBiele\AppData\Roaming\npm\node_modules\cordova\node_
modules\express\node_modules\negotiator'
npm WARN install:vary ENOENT: no such file or directory, rename 'C:\Users\DBiele
\AppData\Roaming\npm\node_modules\cordova\node_modules\express\node_modules\vary
' -> 'C:\Users\DBiele\AppData\Roaming\npm\node_modules\cordova\node_modules\expr
ess\node_modules\vary'
npm WARN install:object-assign ENOENT: no such file or directory, rename 'C:\Use
rs\DBiele\AppData\Roaming\npm\node_modules\cordova\node_modules\got\node_modules
\object-assign' -> 'C:\Users\DBiele\AppData\Roaming\npm\node_modules\cordova\nod
e_modules\got\node_modules\object-assign'
npm WARN install:convert-source-map ENOENT: no such file or directory, rename 'C
:\Users\DBiele\AppData\Roaming\npm\node_modules\cordova\node_modules\insert-modu
le-globals\node_modules\convert-source-map' -> 'C:\Users\DBiele\AppData\Roaming\
npm\node_modules\cordova\node_modules\insert-module-globals\node_modules\convert
-source-map'
npm WARN install:graceful-fs ENOENT: no such file or directory, rename 'C:\Users
\DBiele\AppData\Roaming\npm\node_modules\cordova\node_modules\write-file-atomic\
node_modules\graceful-fs' -> 'C:\Users\DBiele\AppData\Roaming\npm\node_modules\c
ordova\node_modules\read-package-json\node_modules\graceful-fs'
npm WARN install:deep-extend ENOENT: no such file or directory, rename 'C:\Users
\DBiele\AppData\Roaming\npm\node_modules\cordova\node_modules\registry-url\node_
modules\deep-extend' -> 'C:\Users\DBiele\AppData\Roaming\npm\node_modules\cordov
a\node_modules\registry-url\node_modules\deep-extend'
npm WARN install:strip-json-comments ENOENT: no such file or directory, rename '
C:\Users\DBiele\AppData\Roaming\npm\node_modules\cordova\node_modules\registry-u
rl\node_modules\strip-json-comments' -> 'C:\Users\DBiele\AppData\Roaming\npm\nod
e_modules\cordova\node_modules\registry-url\node_modules\strip-json-comments'
npm WARN install:mime-types ENOENT: no such file or directory, rename 'C:\Users\
DBiele\AppData\Roaming\npm\node_modules\cordova\node_modules\request\node_module
s\mime-types' -> 'C:\Users\DBiele\AppData\Roaming\npm\node_modules\cordova\node_
modules\request\node_modules\mime-types'
npm WARN install:qs ENOENT: no such file or directory, rename 'C:\Users\DBiele\A
ppData\Roaming\npm\node_modules\cordova\node_modules\request\node_modules\qs' ->
'C:\Users\DBiele\AppData\Roaming\npm\node_modules\cordova\node_modules\request\
node_modules\qs'
isarray@1.0.0 node_modules\cordova\node_modules\buffer\node_modules\isarray -> n
ode_modules\cordova\node_modules\buffer\node_modules\isarray
negotiator@0.5.3 node_modules\cordova\node_modules\express\node_modules\negotiat
or -> node_modules\cordova\node_modules\express\node_modules\negotiator
accepts@1.2.13 node_modules\cordova\node_modules\express\node_modules\accepts ->
node_modules\cordova\node_modules\express\node_modules\accepts
vary@1.0.1 node_modules\cordova\node_modules\express\node_modules\vary -> node_m
odules\cordova\node_modules\express\node_modules\vary
object-assign@3.0.0 node_modules\cordova\node_modules\got\node_modules\object-as
sign -> node_modules\cordova\node_modules\got\node_modules\object-assign
convert-source-map@1.1.3 node_modules\cordova\node_modules\insert-module-globals
\node_modules\convert-source-map -> node_modules\cordova\node_modules\insert-mod
ule-globals\node_modules\convert-source-map
graceful-fs@4.1.2 node_modules\cordova\node_modules\write-file-atomic\node_modul
es\graceful-fs -> node_modules\cordova\node_modules\read-package-json\node_modul
es\graceful-fs
deep-extend@0.4.0 node_modules\cordova\node_modules\registry-url\node_modules\de
ep-extend -> node_modules\cordova\node_modules\registry-url\node_modules\deep-ex
tend
strip-json-comments@1.0.4 node_modules\cordova\node_modules\registry-url\node_mo
dules\strip-json-comments -> node_modules\cordova\node_modules\registry-url\node
_modules\strip-json-comments
mime-types@1.0.2 node_modules\cordova\node_modules\request\node_modules\mime-typ
es -> node_modules\cordova\node_modules\request\node_modules\mime-types
qs@2.3.3 node_modules\cordova\node_modules\request\node_modules\qs -> node_modul
es\cordova\node_modules\request\node_modules\qs
readable-stream@1.0.33 node_modules\cordova\node_modules\cordova-lib\node_module
s\request\node_modules\bl\node_modules\readable-stream -> node_modules\cordova\n
ode_modules\browser-pack\node_modules\readable-stream
bl@0.9.4 node_modules\cordova\node_modules\cordova-lib\node_modules\request\node
_modules\bl -> node_modules\cordova\node_modules\bl
request@2.47.0 node_modules\cordova\node_modules\cordova-lib\node_modules\reques
t -> node_modules\cordova\node_modules\request
npmconf@2.1.2 node_modules\cordova\node_modules\cordova-lib\node_modules\npmconf
-> node_modules\cordova\node_modules\npmconf
glob@4.0.6 node_modules\cordova\node_modules\cordova-lib\node_modules\glob -> no
de_modules\cordova\node_modules\glob
tar@1.0.2 node_modules\cordova\node_modules\cordova-lib\node_modules\tar -> node
_modules\cordova\node_modules\tar
- C:\Users\DBiele\AppData\Roaming\npm\node_modules\cordova\node_modules\write-fi
le-atomic node_modules\cordova\node_modules\write-file-atomic
C:\Users\DBiele\AppData\Roaming\npm
└── (empty)

npm ERR! code 1

----------------------------更新 2 2016 年 1 月 15 日--------- ----------------现在看来它正在发挥作用!我使用了 Michael Braude 的评论来 npm -g install npm 并且它有效。

但是,在修复之前我做了以下操作:

  1. sử dụng添加和删除程序删除了节点
  2. 通过删除漫游中的 NPM 文件夹来删除 NPM。
  3. 已修复 VS2015

sử dụngnpm -g install npm后,我将nút更新为5.4.1 - 64位,我还检查以确保NPM 3.5 .4 工作并使用了 npm -g install npm@3.5.4 并且它工作了。

此外,我通过将 C:\Program Files (x86)\nodejs 添加到“工具”>“选项”>“项目和解决方案”>“外部 Web”,更改了 Node 和 NPM 的沙盒(我认为?)版本工具nhập mô tả hình ảnh ở đây

我现在可以使用 Task Runner Explorer 运行我的 gulp 任务,而不会出现错误。祈祷它继续有效!

1 Câu trả lời

问题是与“最新稳定”版本的 Node 捆绑在一起的 npm 版本无法正确安装我们的一些 npm 软件包。要解决此问题,请打开命令提示符并运行:

npm -g install npm

将 npm 更新到最新版本。这应该可以解决问题。

编辑 2016 年 2 月 5 日 - 我们发布了更新 6,修复了此问题。请参阅我们的博客了解更多信息:http://microsoft.github.io/vstacoblog/2016/02/04/announcing-update-6.html

(披露:我在 Visual Studio 中开发 Apache Cordova 工具)

关于visual-studio-cordova - 更新 Node 和 NPM VS Cordova 更新 5,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34793930/

33 4 0
行者123
Hồ sơ cá nhân

Tôi là một lập trình viên xuất sắc, rất giỏi!

Nhận phiếu giảm giá Didi Taxi miễn phí
Mã giảm giá Didi Taxi
Giấy chứng nhận ICP Bắc Kinh số 000000
Hợp tác quảng cáo: 1813099741@qq.com 6ren.com