The cmd command is located in C:\Windows\System32\cmd.exe.
Use the SET command to view all environment variables and their corresponding values, and use echo%SystemRoot% to view the values of the environment variables.
The Android Signature tool is located in D:\Java\jdk1.8.0_45\bin\keytool.exe.
1. Create a signature file
At the command line, enter
Keytool-genkey-v-keystore debug.keystore-alias androiddebugkey-storepass android-keypass android-keyalg Rsa-validi Ty 14000
To create a signature tool. If you want to use this signature file as eclipse by default, ensure that the password is android,alias to Androiddebugkey.
2. Sign an unsigned apk
The signature command is located in D:\Java\jdk1.8.0_45\bin\jarsigner.exe. Use the Android Tools->export Unsigned application package to export an unsigned apk.
Where-verbose can see the details of the signature, the-signedjar parameter specifies the name of the file after the signature
3. Use Zipalign to optimize the signed apk
At the command line, type
D:\Android\sdk\build-tools\21.1.2\zipalign-v 4 dbtest_signed.apk dbtest_signed_align.apk
-V indicates output details, 4 provides 32-bit alignment
The creation and use of the Android signature tool