Cordova: Difference between revisions
Jump to navigation
Jump to search
Line 27: | Line 27: | ||
| run android --release || Creates signed .apk || Creates signed .apk | | run android --release || Creates signed .apk || Creates signed .apk | ||
|- | |- | ||
| Create cordova directory only || Creates all files, but does not run a Cordova command. | | Create cordova directory only || Creates all files, but does not run a Cordova command. || Creates all files, but does not run a Cordova command. | ||
|- | |- | ||
| Create and open in Xcode || Nothing || Creates all files, then launches in XCode. | | Create and open in Xcode || Nothing || Creates all files, then launches in XCode. |
Revision as of 15:23, 28 March 2020
Prerequisites
Windows
Android Studio and SDK
MacOS
Android Studio and SDK XCode 11
Cordova Commands
Command | Windows | macOS |
---|---|---|
emulate ios | Nothing | Opens app in iOS Emulator. |
emulate android | Opens app in Android Emulator | Creates debug apk and opens in Android Emulator |
run ios --debug | Nothing | Creates debug ipa and opens app on Emulator or USB connected device. provisioningProfile and developmentTeam must be supplied in build.json. |
run android --debug | Opens app on USB connected device | Creates debug apk and opens on USB connected device |
run ios --release | Nothing | Creates signed ipa and opens app on Emulator or USB connected device. codeSignIdentity, provisioningProfile and developmentTeam must be supplied in build.json. |
run android --release | Creates signed .apk | Creates signed .apk |
Create cordova directory only | Creates all files, but does not run a Cordova command. | Creates all files, but does not run a Cordova command. |
Create and open in Xcode | Nothing | Creates all files, then launches in XCode. |
The full list of command options is in the Cordova documentation.
You can also enter the commands manually. Open a terminal window in {your project}/cordova, and enter one of the commands above or others:
$ cordova platform Installed platforms: android 8.1.0 ios 5.1.1 Available platforms: browser ^6.0.0 electron ^1.0.0 osx ^5.0.0 windows ^7.0.0
Cordova build.json
This file contains parameters for signing apps.
Android
https://cordova.apache.org/docs/en/latest/guide/platforms/android/index.html#signing-an-app
iOS
https://cordova.apache.org/docs/en/latest/guide/platforms/ios/index.html#signing-an-app