Create Android app release mode

落花浮王杯 提交于 2019-11-29 03:09:22

The question is how can I create release mode version of my application from Eclipse

Check this out : Compile the application in the release mode

Android Tools > Export Unsigned Application Package


Support for a true debug build. Developers no longer need to add the android:debuggable attribute to the tag in the manifest — the build tools add the attribute automatically. In Eclipse/ADT, all incremental builds are assumed to be debug builds, so the tools insert android:debuggable="true". When exporting a signed release build, the tools do not add the attribute. In Ant, a ant debug command automatically inserts the android:debuggable="true" attribute, while ant release does not. If android:debuggable="true" is manually set, then ant release will actually do a debug build, rather than a release build.

Pir Fahim Shah

If you want to SIGNED IN and ZIP ALIGNED your app in release mode so that it could distribute and can be uplodated to the Google play store, then just follow the below steps.

 --> Right click on project
 --> Android Tools
 --> Export Unassigned app and save in directory like D:\Sdcard.apk

         //Now open your windows terminal, CMD
 --> change directory to the bin of the jave like
 --> cd c:\ProgramFiles\JAVA\JDK\bin

Now this is time to create Keystore Released File... now write these commands in the TERMINAL,

keytool -genkey -v -keystore my-release-key.keystore -keyalg RSA -keysize 2048 -validity 14600

This will propmt for Keystore "password" and for Key "password", so type different password and answer to the question it will ask later. Now my-release-key.keystore file will be generated in directory where your "bin" folder of java are, like in my sytstem it will be like

     c:\ProgramFiles\JAVA\JDK\bin\ my-release-key.keystore

write this command in Terminal for Signed in the app

jarsigner -verbose -keystore my-release-key.keystore D:\Sdcard.apk mykey

Now redirect your terminal to the Zipalign.exe file which is located in Android sdk 21\tool\ , like in my system i did that

cd F:\Softwares\LANGUAGES SOFTEARE\Android Setup\android-sdk-21 version\tools

After that put the below line in the terminal

zipalign -v 4 D:\Sdcard.apk newSdcard.apk

Congratulations! - Now you will find a newSdcard.apk file inside the Android sdk\tool, Now upload it to play store, and remember me with love. 💖

On current versions of the Android SDK, just right-click the project, Android Tools > Export Signed Application Package, and select your keystore

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!