Struct crossbundle_tools::types::Bundletool
source · [−]pub struct Bundletool;
Expand description
Bundletool
bundletool
is the underlying tool that Android Studio, the Android Gradle plugin,
and Google Play use to build an Android App Bundle, and convert an app bundle into
the various APKs that are deployed to devices. Bundletool
is also available to you
as a command line tool, so you can build app bundles yourself and recreate
Google Play’s server-side build of your app’s APKs.
Download bundletool
If you haven’t already done so, download bundletool from the [GitHub repository
].
Install bundletool
In variable environments needs to create new variable BUNDLETOOL_PATH
and add
path to the bundletool
Implementations
sourceimpl Bundletool
impl Bundletool
sourcepub fn build_apks(self, bundle: &Path, output: &Path) -> BuildApks
pub fn build_apks(self, bundle: &Path, output: &Path) -> BuildApks
Generate an APK set for all device configurations your app supports from your app bundle
sourcepub fn build_bundle(self, modules: &[PathBuf], output: &Path) -> BuildBundle
pub fn build_bundle(self, modules: &[PathBuf], output: &Path) -> BuildBundle
Generate AAB file from generated zip modules to specified path. Notice, that zip module must contents files in protobuf format
sourcepub fn get_size_total(self, apks: &Path) -> GetSizeTotal
pub fn get_size_total(self, apks: &Path) -> GetSizeTotal
To measure the estimated download sizes of APKs in an APK set as they would be served compressed over-the-wire, use the get-size total
sourcepub fn extract_apks(
self,
apks: &Path,
output_dir: &Path,
device_spec: &Path
) -> ExtractApks
pub fn extract_apks(
self,
apks: &Path,
output_dir: &Path,
device_spec: &Path
) -> ExtractApks
Extract device-specific APKs from an existing APK set If you have an existing APK set and you want to extract from it a subset of APKs that target a specific device configuration, you can use the extract-apks command and specify a device specification JSON
sourcepub fn install_apks(self, apks: PathBuf) -> InstallApks
pub fn install_apks(self, apks: PathBuf) -> InstallApks
Use the install-apks command and specify the path of the APK set to deploy your app from an APK set
sourcepub fn get_device_spec(self, output: &Path) -> GetDeviceSpec
pub fn get_device_spec(self, output: &Path) -> GetDeviceSpec
Generate and use device specification JSON files. Bundletool is capable of generating an APK set that targets a device configuration specified by a JSON file. To first generate a JSON file for a connected device, run the command
Trait Implementations
sourceimpl Clone for Bundletool
impl Clone for Bundletool
sourcefn clone(&self) -> Bundletool
fn clone(&self) -> Bundletool
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Copy for Bundletool
Auto Trait Implementations
impl RefUnwindSafe for Bundletool
impl Send for Bundletool
impl Sync for Bundletool
impl Unpin for Bundletool
impl UnwindSafe for Bundletool
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more