After building our Android app in the last session, we ended up having the final product as android-debug.apk as seen in the build message console below.
How to Sign Android App

Our final application was debug apk file which can only  be used for development purposes.However, when  if we want to publish our app in play store or AppStore and also share with our friends, we will be required to  have or build a release apk file.

The  main differences between a debug file and release file apk is that release  apk file is more optimized and doesn't  contain any debugged symbols.Release apks are also  digitally signed which makes it easy for devices to install easily as they from verified publishers as compared to their counterparts the debug apk files which are signed using the development certificates which are usually generated automatically by Android SDK tool.

Every mobile application has to be digitally signed with a unique  signature which will be used to identify the publisher of the app or the owner. Now, lets sign our apk and the first thing we need is to generate our own certificate.To do this,go to your command line and type this code as shown below ;

How to Sign Android App
After that change the destination of the key file  which is "my-release-key" to one which you may desire and also change the name of it to yours in the "alias-name" as shown below.
How to Sign Android App
After that you will be prompted to fill in some few details so as to set up your full profile as the owner of application as shown here  below.
How to Sign Android App
The next thing we need is  to create the release apk version which we will do it by using  ionic command  such as ionic build   --release android, and in no time your release build which is unsigned will be ready as shown below.
How to Sign Android App
After the above process is done,it is now our turn sign the unsigned apk file using the ionic jarsigner command as shown here below;
How to Sign Android App
The final step of getting our release apk is to align it for the purposes of optimization as required by the Android standards.To align it,we  will use the zip align command from ionic  as shown here  below;
How to Sign Android App

Now the zip aligned app is our final product which we will need to upload in play store and also share  with our friends.If you have experienced any problem in signing your apk let me know and i will be of great help to you.

Enjoy and dont forget to share my posts with your friends.stay tuned for greater posts.

Post a Comment Blogger

 
Top