Skip to content

Commit

Permalink
new method og generating APK and signing it
Browse files Browse the repository at this point in the history
  • Loading branch information
jfoclpf committed Jun 10, 2023
1 parent 728b5bc commit 06f0370
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions scripts/buildReleaseAPK.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,16 @@ source keys/keyPassword

cordova clean

cordova build --release android
cordova build --release android -- --packageType=apk

cp keys/autocosts.keystore platforms/android/app/build/outputs/apk/release/
cd platforms/android/app/build/outputs/apk/release/

jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore autocosts.keystore -storepass $PASS app-release-unsigned.apk autocosts
# old method
#jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore autocosts.keystore -storepass $PASS app-release-unsigned.apk autocosts

zipalign -v 4 app-release-unsigned.apk formParkingViolation.apk
apksigner sign --ks autocosts.keystore --pass-encoding utf-8 --ks-key-alias autocosts --ks-pass pass:$PASS --key-pass pass:$PASS formParkingViolation.apk

cd ../../../../../../..
rm -f dist/formParkingViolation.apk
Expand Down

0 comments on commit 06f0370

Please sign in to comment.