cordova-cli

Can't add module dependency to CordovaLib for Cordova project using Android Studio

冷暖自知 提交于 2019-12-10 14:32:54
问题 I can't workout how to add the CordovaLib directory as a module dependency in Android Studio. (NOTE: this is the first time I've ever used Android Studio, so possibly I just don't know what I'm doing) I'm using: OSX Yosemite Android Studio 1.1.0 Cordova 4.3 Here are the steps I have taken: Create new cordova project Add android platform and some cordova plugins Import the generated project into Android Studio (NOTE: when it asks about the gradle wrapper, I say no and just point it to where I

cordova edit-config not updating AndroidManifest.xml

风格不统一 提交于 2019-12-10 10:26:25
问题 I am trying to update the AndroidManifest.xml file with the following in config.xml: <platform name="android"> <edit-config file="app/src/main/AndroidManifest.xml" mode="merge" target="/manifest/application"> <application android:icon="@mipmap/appicons" android:roundIcon="@mipmap/appicons_round" /> </edit-config> </platform> and it doesn't update anything. I tried to remove the full path and just leave it as file="app/src/main/AndroidManifest.xml" and that's also not working. I am using

Cordova 4.3.0 - build command returns error Cannot find module 'Q'

最后都变了- 提交于 2019-12-09 06:07:43
问题 After updating cordova to version 4.3.0 the command: cordova build returns the following error: module.js:340 throw err; ^ Error: Cannot find module 'Q' at Function.Module._resolveFilename (module.js:338:15) at Function.Module._load (module.js:280:25) at Module.require (module.js:364:17) at require (module.js:380:17) at Object.<anonymous> (/Volumes/CaseSensitive/ios_projects/_Tests/testGruntCordova/testGruntCordova/platforms/ios/cordova/lib/check_reqs.js:25:13) at Module._compile (module.js

Cordova DeviceReady not firing

耗尽温柔 提交于 2019-12-08 14:30:25
问题 I've been banging my head on this one for a few days. After getting a number of "object not defined" errors when trying to create a new FileTransfer() object, it looks like the problem is more basic -- somehow the DeviceReady event is not firing. Stack Overflow has a lot of hits on this issue, but most of them have to do with pre-3.x cordova builds that had a different architecture (I'm on 4.1.2). I've tried the suggestions in the newer topics I could find -- removing and adding plugins,

Error: ANDROID_HOME is not set and “android” command not in your PATH on OS X

馋奶兔 提交于 2019-12-07 03:50:36
问题 I am getting this error in terminal when attempting to execute this command: $ cordova platform add android I read these answers here: Error: ANDROID_HOME is not set and "android" command not in your PATH. You must fulfill at least one of these conditions ANDROID_HOME is not set and "android" command not in your PATH Phonegap however I don't know where to place the code they provide. I am running OS X. 回答1: Option 1 for windows Right click on My computer -> properties -> Advanced system

cordova edit-config not updating AndroidManifest.xml

久未见 提交于 2019-12-05 22:06:25
I am trying to update the AndroidManifest.xml file with the following in config.xml: <platform name="android"> <edit-config file="app/src/main/AndroidManifest.xml" mode="merge" target="/manifest/application"> <application android:icon="@mipmap/appicons" android:roundIcon="@mipmap/appicons_round" /> </edit-config> </platform> and it doesn't update anything. I tried to remove the full path and just leave it as file="app/src/main/AndroidManifest.xml" and that's also not working. I am using command line with Android 7.0.0 and I'm absolutely lost. Both config.xml and AndroidManifest.xml pass XML

Error: ANDROID_HOME is not set and “android” command not in your PATH on OS X

谁说胖子不能爱 提交于 2019-12-05 07:01:39
I am getting this error in terminal when attempting to execute this command: $ cordova platform add android I read these answers here: Error: ANDROID_HOME is not set and "android" command not in your PATH. You must fulfill at least one of these conditions ANDROID_HOME is not set and "android" command not in your PATH Phonegap however I don't know where to place the code they provide. I am running OS X. Prem Option 1 for windows Right click on My computer -> properties -> Advanced system setting -> Environment Variables Now Edit Path on system variables to ;/yourSdkHome/tools;/youSdkHome

Cordova 4.3.0 - build command returns error Cannot find module 'Q'

微笑、不失礼 提交于 2019-12-03 07:55:13
After updating cordova to version 4.3.0 the command: cordova build returns the following error: module.js:340 throw err; ^ Error: Cannot find module 'Q' at Function.Module._resolveFilename (module.js:338:15) at Function.Module._load (module.js:280:25) at Module.require (module.js:364:17) at require (module.js:380:17) at Object.<anonymous> (/Volumes/CaseSensitive/ios_projects/_Tests/testGruntCordova/testGruntCordova/platforms/ios/cordova/lib/check_reqs.js:25:13) at Module._compile (module.js:456:26) at Object.Module._extensions..js (module.js:474:10) at Module.load (module.js:356:32) at

cordova build error Exit code 1

夙愿已清 提交于 2019-12-01 14:48:42
I have created referred - https://cordova.apache.org/docs/en/latest/guide/cli/index.html#installing-the-cordova-cli for creating first cordova android app. I was able t create project and add android platform, but could not build cordova, following error appeared. Following is the commands executed from command prompt It looks more of a network issue. The gradle download will fail if you are using restricted proxy network. In case of network restrictions, you can work around this issue by following the steps below: 1) Download the required gradle version zip file from gradle distribution link

cordova build error Exit code 1

不羁岁月 提交于 2019-12-01 13:29:02
问题 I have created referred - https://cordova.apache.org/docs/en/latest/guide/cli/index.html#installing-the-cordova-cli for creating first cordova android app. I was able t create project and add android platform, but could not build cordova, following error appeared. Following is the commands executed from command prompt 回答1: It looks more of a network issue. The gradle download will fail if you are using restricted proxy network. In case of network restrictions, you can work around this issue