English Android guide 简体中文 Android 指南

# Android App This directory contains the complete buildable Haoleme Android app project. ## Requirements - JDK 17 - Android SDK 35 ## Build and Test ```bash cd android ./gradlew testDebugUnitTest ./gradlew assembleDebug ``` The debug APK is written to `app/build/outputs/apk/debug/`. ## Self-hosted Endpoint The default build connects to the official Haoleme HTTPS service. For a self-hosted build, override the server and update manifest from the command line: ```bash ./gradlew assembleDebug \ -PHAOLEME_DEFAULT_SERVER_URL=https://haoleme.example.com \ -PHAOLEME_UPDATE_URLS=https://haoleme.example.com/downloads/update.json ``` ## Release Signing Official signing materials are not stored in this repository. Release builds read their signing configuration from these environment variables: ```bash export HAOLEME_ANDROID_KEYSTORE=/private/path/release.jks export HAOLEME_ANDROID_KEYSTORE_PASSWORD='...' export HAOLEME_ANDROID_KEY_ALIAS='...' export HAOLEME_ANDROID_KEY_PASSWORD='...' ./gradlew assembleRelease ``` Without these variables, the release task uses the local debug signing key and is suitable only for development and testing. Do not commit keystores, passwords, `local.properties`, `.env`, or `google-services.json`.