Ionic Android App release guide

Source: Internet
Author: User

During the process of creating a project, you often forget about the packaging process of the release and record it.

Before you begin

Learn two things first:

    1. Keytool is an effective security key and certificate management tool.
    2. Android requires that all programs must have a signature, otherwise the program will not be installed.

Generate commands

注意: Remember to alias_name change it.

$ keytool -genkey -v -keystore my-release-key.keystore -alias alias_name -keyalg RSA -keysize 2048 -validity 10000

Forgetting to change this name before is a big problem. Here are some questions to ask you:

password:Re-enter new password:What is your first and last name? [Unknown]: phodalWhat is the name of your organizational unit? [Unknown]: phodalWhat is the name of your organization? [Unknown]: phodalWhat is the name of your City or Locality?

注意: If you want to publish your app to some app market, your signature will be saved, and if the signature is inconsistent, it will indicate a problem ...

Build Android Apps

1. Generate Release Package

Cordova provides a set of device-related APIs that enable mobile apps to access native device features, such as cameras, microphones, and so on, with JavaScript.

--release android

2. Signature

Jarsigner is a tool that is included in the JDK for the signature and validation of jar files.

$jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore my-release-key.keystore HelloWorld-release-unsigned.apk alias_name

注意: The alias_name should be consistent with the above

3. Optimization

Zipalign is a tool for organizing apk files on an Android platform, and it was first introduced in the SDK Software Development Kit for Android version 1.6. It is able to optimize packaged Android applications to make the interaction between the Android operating system and the application more efficient, which allows applications and the entire system to run faster.

 $zipalign -v 4 HelloWorld-release-unsigned.apk HelloWorld.apk

注意: Normally zipalign should be under one of the versions of the SDK in the home directory of your Android SDK under Build-tools.

Turn from 1190000002617037

Ionic Android App release guide

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.