Forrest logo
back to the bundletool tool

bundletool-dump:tldr:64e15

bundletool-dump: Display a specific value from the `AndroidManifest.xml` using XPath.
$ bundletool dump manifest --bundle=${path-to-bundle-aab} --xpath=${-manifest-@android:versionCode}
try on your machine

The command provided is using the "bundletool" tool to extract the version code from an Android App Bundle (AAB) file.

Here's a breakdown of the different elements in the command:

  • bundletool: Refers to the executable or command-line tool "bundletool".
  • dump manifest: The "dump" command is used to extract information from an AAB file, and "manifest" specifies that we want to extract the Android manifest information.
  • --bundle=${path-to-bundle-aab}: Specifies the path to the AAB file from which the manifest information will be extracted. You need to replace ${path-to-bundle-aab} with the actual file path.
  • --xpath=${-manifest-@android:versionCode}: Specifies the XPath expression that identifies the version code attribute in the manifest file. The XPath expression is ${-manifest-@android:versionCode}. The @android:versionCode part denotes the "versionCode" attribute in the Android manifest.

To use this command, you need to have the "bundletool" tool installed on your system. It is typically used for working with Android App Bundles, such as extracting APKs or extracting information from the AAB file. The extracted version code can be useful for various purposes, such as checking the version of the app or performing automated processes based on the version code.

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the bundletool tool