Tuesday, 8 January 2019

android bundle


https://developer.android.com/platform/technology/app-bundle/

https://developer.android.com/guide/app-bundle/


--How to setup bundle for new project:
https://android.jlelse.eu/a-practical-guide-to-android-app-bundle-for-beginners-7e8d93831828



--How to use bundle tool:

https://developer.android.com/studio/command-line/bundletool

https://github.com/google/bundletool

https://medium.com/mindorks/android-app-bundle-part-2-bundletool-6705b50bea4c



install aab file into a device:


1. download bundletool from here first:
https://github.com/google/bundletool/releases

2. generate aab file from android studio, Build->generate signed bundle/apks -> bundle ....

3. run below command to convert the aab file to apks file:
java -jar ./bundletool-all-0.7.2.jar  build-apks --bundle=app.aab  --output=./aaa.apks --ks=pathtoyoukeystorefile --ks-pass=pass:keystorepassword --ks-key-alias=test --key-pass=pass:keypassword

4. run below command to install the apks file into a connected device.
java -jar ./bundletool-all-0.7.2.jar  install-apks --apks=aaa.apks   --adb=/Users/peterwang/Library/Android/sdk/platform-tools/adb



if your app is big , this may take a while to finish.

No comments:

Post a comment