生成密钥
1 | keytool -genkey -v -keystore app-release-key.keystore -alias app-release-key.keystore -keyalg RSA -keysize 2048 -validity 10000 |
签名apk
1 | jarsigner -verbose -sigalg SHA256withRSA -tsa https://timestamp.geotrust.com/tsa -digestalg SHA1 -keystore app-release-key.keystore app-release-unsigned.apk app-release-key.keystore |
优化APK
1 | zipalign -v 4 app-release-unsigned.apk app-1.0.0.apk |