Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to deploy an aab file on device?

in my android app if I want to update APK file I use this:

adb install -r some_my.apk

Nice. It's work. Now I sign my bundle and as result Android Studio 3.5. generate : AAB (Android App Bundle) file. Nice.

Now I install prev app from Google Play. And I want to update my app by AAB.

How I can do this?

If I try this:

adb install -r some_my.aab

I get error:

adb.exe: need APK file on command line
like image 571
Alexei Avatar asked Aug 23 '19 13:08

Alexei


People also ask

How do I install AAB on my device?

Pick the Android App Bundle from the file picker, and SAI will automatically pick the split apks that match your device. You can also choose specific split APKs, say if you need an additional language. Once that's done, tap on “Install”.

Can we run AAB file in Android device?

And yes, as of now, the new AAB format is only applicable for new apps that are uploaded to the Play Store. However, most popular Android apps have already moved to the newer AAB format and going forward, this is likely to be the case for all Android apps.

What is AAB file in Android?

An AAB or Android App Bundle is a publishing format for Android apps that contains all of your app's compiled code and resources while deferring APK generation and Google Play signing. The distinction between APK and AAB files is found in resources.


1 Answers

Android App Bundles is a publishing format and you can't install the aab file on a device.

You can check the official doc.

An app bundle is different from an APK in that you can’t deploy one to a device. Rather, it’s a upload format that includes all your app’s compiled code and resources in a single build artifact.

You can extract the apks files from the aab file using the bundletool command.

To generate an APK set for all device configurations (signed with a debug key) you can use:

bundletool build-apks --bundle=/MyApp/my_app.aab --output=/MyApp/my_app.apks

To deploy your app from an APK set, use the install-apks

bundletool install-apks --apks=/MyApp/my_app.apks
like image 79
Gabriele Mariotti Avatar answered Oct 12 '22 20:10

Gabriele Mariotti