new·The score now tells you which way it movedA brain's exam only ever grows: its own material writes questions, and so does every question a real caller asked and did not get answered. The score is a percentage over that growing set, so a brain that learned more could post a smaller number — and this week three did. One of them answered two MORE questions than the week before and showed eighteen points less. Printed as a single percentage, that reads as decline to a reader and as punishment to anyone who contributes material.all news →
mozg.beta
Sign in

Expo & React Native · all subjects

android build process

16 notes, read out of this brain and free to use. Each one was extracted from a source and is re-checked against its exam.

Android gradleCommand configuration

The Gradle command run during Android builds is configured at builds.android.PROFILE_NAME.gradleCommand in eas.json and defaults to :app:bundleRelease, which produces the AAB (Android App Bundle).

Android build local steps in EAS CLI

Local steps for Android builds occur on your computer via EAS CLI: (1) If cli.requireCommit is true in eas.json, check that git index is clean—no uncommitted changes—or offer to commit or abort. (2) Prepare credentials unless builds.android.PROFILE_NAME.withoutCredentials is true, obtaining them from local credentials.json or EAS servers based on credentialsSource value. (3) Create a tarball of the repository following the VCS workflow. (4) Upload the tarball to a private Google Cloud Storage bucket and send the build request to EAS Build.

Android build remote steps on EAS Build

Remote steps for Android builds on EAS Build: (1) Create a fresh Docker container with Java JDK, Android SDK, NDK, and build tools installed. (2) Download and unpack the project tarball from GCS. (3) Create .npmrc if NPM_TOKEN is set. (4) Run eas-build-pre-install script if defined. (5) Run npm install or yarn install. (6) Run npx expo-doctor. (7) For CNG projects, run npx expo prebuild. (8) Restore cache by cache.key value. (9) Run eas-build-post-install script if defined. (10) Restore keystore if included. (11) Inject signing configuration into build.gradle. (12) Run ./gradlew COMMAND in android directory (default: :app:bundleRelease for AAB). (13) Run eas-build-pre-upload-artifacts script if defined (deprecated). (14) Store cache. (15) Upload artifact to GCS from path configured at builds.android.PROFILE_NAME.applicationArchivePath (default: android/app/build/outputs/**/*.{apk,aab}). (16) Run eas-build-on-success, eas-build-on-error, or eas-build-on-complete scripts as appropriate. (17) Upload build artifacts archive if buildArtifactPaths is specified.

Gradle signing configuration injection in EAS Build

EAS Build injects signing configuration into a generated file at android/app/eas-build.gradle before building. This file defines Android signingConfigs.release and buildTypes (release and debug) that read keystore credentials from credentials.json at project root. The release signing config reads: storeFile (keystorePath as absolute or relative path), storePassword, keyAlias, and keyPassword (or keystorePassword if keyPassword key is absent). The release and debug buildTypes both use signingConfig android.signingConfigs.release. The android/app/build.gradle imports this file with 'apply from: "./eas-build.gradle"'.

Android keystore security requirements

Android keystores must be kept private and never checked into a repository; debug keystores are the only exception as they are not used for uploading to Google Play Store. The keystore is essential—losing it may prevent app updates in the store, though Play App Signing can mitigate this risk.

credentials.json structure for Android signing

The credentials.json file at project root contains Android signing configuration with the structure: credentials.android.keystore.keystorePath (file path), credentials.android.keystore.keystorePassword (store password), credentials.android.keystore.keyAlias (key alias), and optionally credentials.android.keystore.keyPassword (key password, or keystorePassword is used if absent).

Android credentialsSource configuration options

The builds.android.PROFILE_NAME.credentialsSource setting determines where credentials are obtained: either from the local credentials.json file or from EAS servers. If remote mode is selected but no credentials exist, the user is prompted to generate a new keystore.

Android applicationArchivePath configuration

The artifact path in Android builds is configured via builds.android.PROFILE_NAME.applicationArchivePath in eas.json and defaults to android/app/build/outputs/**/*.{apk,aab}. This uses glob patterns for matching.

Default Android build format is AAB, not APK

The default file format used when building Android apps with EAS Build is an Android App Bundle (AAB/**.aab**), which is optimized for distribution to the Google Play Store. AABs cannot be installed directly on a device.

APK required for direct device installation

To install a build directly to an Android device or emulator, you need to build an Android Package (APK/**.apk**) instead of an AAB.

Auto-install APK on Android Emulator during build

After the build is completed, the CLI will prompt you to automatically download and install it on the Android Emulator. Press Y to directly install it on the emulator.

eas build:run command for emulator

Run eas build:run -p android at any time to download a specific build and automatically install it on the Android Emulator. The command shows a list of available builds with build ID, time elapsed, build number, version number, and git commit information.

Install latest build on Android Emulator

Pass the --latest flag to eas build:run command to download and install the latest build on the Android Emulator: eas build:run -p android --latest

Install APK on physical Android device directly

Copy the URL to the APK from the build details page or from the link provided when eas build is done. Send that URL to your device and open it on the device to install and run the APK.

Install APK on physical device with adb

Install adb if not already installed. Connect your device to your computer and enable adb debugging on your device. Download the APK from the build details page. Run adb install path/to/the/file.apk. Run the app on the device.

EAS Build Maven cache server for Android dependencies

EAS Build runs a Maven cache server that caches dependencies from maven-central (https://repo1.maven.org/maven2/), google (https://maven.google.com/), and plugins (https://plugins.gradle.org/m2/). To disable the Maven cache server, set the EAS_BUILD_DISABLE_MAVEN_CACHE environment variable to "1" in eas.json or in a job's env if using EAS Workflows.

Give your agent this brain