Converting Sencha Touch 2 in Android.

C

Requirement  –Android SDK Tools

Steps to package your Android application

1-     Obtain an appropriate Android ready certificate (debug or release) for signing the application

2-     Install Sencha SDK Tools (SenchaSDKTools 2.0).

3-     Create a packaging configuration file to be use with the packager.

4-     Run the packager to create a packaged .apk.

Create a packaging configuration file to be used with the native packager.

Code- Packager.json

{

“applicationName”: “<AppName>”,

“applicationId”: “<AppID>”,

“outputPath”: “<AppPackageOutputPath>”,

“iconName”: “<AppIconName>”,

“versionString”: “<AppVersion>”,

“inputPath”: “<PathToWebApp>”,

“configuration”: “<Release | Debug>”,

“platform”: “<Android | AndroidEmulator>”,

“certificatePath”: “<certificatePath>”,

“certificateAlias”: “<certificateAlias>”,

“sdkPath”: “/android-sdk-mac_86”,

“orientations”: [

“portrait”,

“landscapeLeft”,

“landscapeRight”,

“portraitUpsideDown”

],

“deviceType”: “<Not applicable for Android>”

}

If Our Application Name ListDemo then Code-

{

“applicationName”:”ListDemo”,

“applicationId”:”com.ListDemo”,

“versionString”:”1.0″,

“iconName”:”resources/icons/Icon.png”,

“inputPath”:”E:/wamp/www/ListDemo”,

“outputPath”:”E:/build”,

“webAppPath”:”E:/wamp/www”,

“configuration”:”Debug”,

“platform”:”Android”,

“deviceType”:”Universal”,

“certificatePath”:”mykeystore.keystore”,

“certificateAlias”:”alias”,

“sdkPath”:”C:/android”,

“androidAPILevel”:”13″,

“orientations”: [

“portrait”,

“landscapeLeft”,

“landscapeRight”,

“portraitUpsideDown”

]

}

Run the packager to create a packaged ListDemo.apk

Command –

sencha package run packager.json

it will create ListDemo.apk

About the author

swati nuna
By swati nuna

Category