My APK file is already signed (with jarsigner) and compressed (with zipalign). I do it via a bash script. Though I'm getting a warning in Play Console to use Android App Bundle:
Reduce the size of your next release using the Android App Bundle. Your app could be 15.4% smaller if you used the Android App Bundle.
I know I have to use bundletool to use it in command line. The documentation is though too long and cumbersome.
Imagine I have such a file myApp.apk (already signed and compressed). Which command should I run to have the Android App Bundle file to upload to Google Play Console?
It's very simple. You can create android app bundles (.aab) file from android source by this command :
gradlew bundle
OR
gradle bundle
You cannot simply convert an APK to an App Bundle. You have to use a build system that supports building App Bundles from source, like Android Studio (which uses Android Gradle plugin) or others.
Bundletool has a build-bundle command but it is meant to use by build systems since you need already precompiled dex code, and resources compiled in a proto format.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With