Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
329 views
in Technique[技术] by (71.8m points)

android - cmd: Command failed with exit code ENOENT

Hey Guys i'm a beginner app developer and i chose phonegap please see the problem while adding android as a platform for my project Here's The Code:

c:UserspshewaleDesktopphone gaphello>phonegap platform add android
npm
 http GET https://registry.npmjs.org/cordova-android

npm http 304 https://registry.npmjs.org/cordova-android

Adding android project...

Error: cmd: Command failed with exit code ENOENT
    at ChildProcess.whenDone (C:UserspshewaleAppDataRoaming
pm
ode_modules
phonegap
ode_modulescordova
ode_modulescordova-libsrccordovasuperspawn.j
s:134:23)
    at ChildProcess.emit (events.js:107:17)
    at Process.ChildProcess._handle.onexit (child_process.js:1072:12)
    at child_process.js:1144:20
    at process._tickCallback (node.js:355:11)

UPDATE:Thanks I Think It Moved A Bit Ahead But Now It Shows This:

    C:Userspshewalehi>cordova platform add android
npm http GET https://registry.npmjs.org/cordova-android
npm http 200 https://registry.npmjs.org/cordova-android
npm http GET https://registry.npmjs.org/cordova-android
npm http 200 https://registry.npmjs.org/cordova-android
npm http GET https://registry.npmjs.org/cordova-android/-/cordova-android-4.0.2.
tgz
npm http 200 https://registry.npmjs.org/cordova-android/-/cordova-android-4.0.2.
tgz
Adding android project...
Error: cmd: Command failed with exit code ENOENT
    at ChildProcess.whenDone (C:UserspshewaleAppDataRoaming
pm
ode_modules
cordova
ode_modulescordova-libsrccordovasuperspawn.js:134:23)
    at ChildProcess.emit (events.js:107:17)
    at Process.ChildProcess._handle.onexit (child_process.js:1072:12)
    at child_process.js:1144:20
    at process._tickCallback (node.js:355:11)

C:Userspshewalehi>
See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Please add C:WindowsSystem32 in your PATH variable


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...