我一直在寻找以下问题的解决方案超过3天。我发现当我添加inappbrowser插件时会发生这种情况,而不会成功编译。 Phonegap版本 3.3.0-0.19.6
但是它可以在我的本地机器上运行。
/Users/Shared/Jenkins/Home/workspace/Project Dev Build/node_modules/phonegap/node_modules/cordova/node_modules/q/q.js:126
throw e;
^
TypeError: Cannot read property 'install' of undefined
at /Users/Shared/Jenkins/Home/workspace/Project Dev Build/node_modules/phonegap/node_modules/cordova/node_modules/plugman/src/install.js:361:71
at Array.forEach (native)
at handleInstall (/Users/Shared/Jenkins/Home/workspace/Project Dev Build/node_modules/phonegap/node_modules/cordova/node_modules/plugman/src/install.js:360:40)
at /Users/Shared/Jenkins/Home/workspace/Project Dev Build/node_modules/phonegap/node_modules/cordova/node_modules/plugman/src/install.js:331:20
at _fulfilled (/Users/Shared/Jenkins/Home/workspace/Project Dev Build/node_modules/phonegap/node_modules/cordova/node_modules/q/q.js:798:54)
at self.promiseDispatch.done (/Users/Shared/Jenkins/Home/workspace/Project Dev Build/node_modules/phonegap/node_modules/cordova/node_modules/q/q.js:827:30)
at Promise.promise.promiseDispatch (/Users/Shared/Jenkins/Home/workspace/Project Dev Build/node_modules/phonegap/node_modules/cordova/node_modules/q/q.js:760:13)
at /Users/Shared/Jenkins/Home/workspace/Project Dev Build/node_modules/phonegap/node_modules/cordova/node_modules/q/q.js:574:44
at flush (/Users/Shared/Jenkins/Home/workspace/Project Dev Build/node_modules/phonegap/node_modules/cordova/node_modules/q/q.js:108:17)
at process._tickCallback (node.js:415:13)
Build step 'Execute shell' marked build as failure
答案 0 :(得分:1)
出现同样的问题,根据https://issues.apache.org/jira/browse/CB-6008中的建议,我将cordova npm update -g cordova
更新为最新版本,然后才有效。
npm update -g phonegap
会做同样的事情。