PhoneGap中文网
标题: Cordova创建工程报错,急求帮助! [打印本页]
作者: eacolt 时间: 2017-5-25 18:01
标题: Cordova创建工程报错,急求帮助!
大家好,请教一个棘手的问题!
我的是MACBook, JDK版本是1.6, cordova是最新的7.01还有 npm是4.2
然后我在用cordova创建项目名字叫coolgame:cordova create coolgame com.cordova.coolgame CoolGame
就
Error: Uncaught, unspecified "error" event. ( Error from Cordova Fetch: Error: npm: Command failed with exit code 254 Error output:
npm ERR! not a package /usr/local/lib/node_modules/.cordova_npminstall/node_modules/.3.12.0@cordova-app-hello-world/index.js
npm ERR! addLocal Could not install /usr/local/lib/node_modules/.cordova_npminstall/node_modules/.3.12.0@cordova-app-hello-world/index.js
npm ERR! Darwin 16.5.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "/usr/local/lib/node_modules/.cordova_npminstall/node_modules/.3.12.0@cordova-app-hello-world/index.js"
npm ERR! node v7.10.0
npm ERR! npm v4.2.0
npm ERR! path /tmp/npm-23173-e16c26c0/unpack-4e9e3f53/package.json
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall open
npm ERR! enoent ENOENT: no such file or directory, open '/tmp/npm-23173-e16c26c0/unpack-4e9e3f53/package.json'
npm ERR! enoent ENOENT: no such file or directory, open '/tmp/npm-23173-e16c26c0/unpack-4e9e3f53/package.json'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! Please include the following file with any support request:
npm ERR! /Users/liuzhaoting/.npm/_logs/2017-05-25T08_03_37_392Z-debug.log)
然后就没有然后了,工程创建不出来,报了一大堆红色的错误,请问这是什么原因呢!急求答案
作者: roshen 时间: 2017-6-16 11:55
楼主解决了吗??我也遇到这样的问题~
作者: duqianchen 时间: 2017-7-15 11:00
兄弟解决了没?方便告知下怎么解决的不
作者: vfv 时间: 2017-9-8 11:27
看看自己的npm全局包里是不是安装了node-uuid,我也是同样的问题,用npm 安装全局Cordova是报错发现的,我的全局目录在 C:\Users\...\AppData\Roaming\npm\node_modules 看看有没 node-uuid 安装后再用npm 安装一遍就好了
欢迎光临 PhoneGap中文网 (http://bbs.phonegap100.com/) |
Powered by Discuz! X3.2 |