Android Build logo

Android Build

Community
hyperb1iss
android-build

Use when building Android apps (Gradle CLI) or ROMs (AOSP, LineageOS). Triggers on "gradle build", "assemble", "AOSP", "LineageOS", "lunch", "mka", "breakfast", "brunch", "compile android", "device tree", "kernel build".

Overview

Publisherhyperb1iss
Repositoryhyperdroid-skill
Skill nameandroid-build
Stars
52
Forks
0
Bundled files
2
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 2 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by hyperb1iss on GitHub. Read the source before you install it.

Installation

Install the Android Build AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/hyperb1iss/hyperdroid-skill/tree/main/skills/android-build
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/hyperb1iss/hyperdroid-skill.git /tmp/hyperdroid-skill
mkdir -p .claude/skills
cp -r /tmp/hyperdroid-skill/skills/android-build .claude/skills/android-build
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Android Build in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Android Build on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Android Build is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Android Build Systems

This skill covers building Android apps via Gradle CLI and building custom ROMs via AOSP/LineageOS.


App Building (Gradle CLI)

Essential Commands

bash
./gradlew tasks                     # List available tasks
./gradlew assembleDebug             # Build debug APK
./gradlew assembleRelease           # Build release APK
./gradlew installDebug              # Build + install to device
./gradlew bundleRelease             # Build AAB (App Bundle)

# APK output location
# app/build/outputs/apk/debug/app-debug.apk
# app/build/outputs/apk/release/app-release.apk

Build Variants

bash
./gradlew assembleFreeDebug         # Flavor + build type
./gradlew assemblePaidRelease
./gradlew assembleDebug --info      # Verbose output
./gradlew assembleRelease -x test   # Skip tests

Testing

bash
./gradlew test                      # Unit tests
./gradlew testDebugUnitTest         # Debug unit tests only
./gradlew connectedAndroidTest      # Instrumented tests
./gradlew connectedCheck            # All connected tests

# Run specific test
./gradlew test --tests "*.MyTestClass"

Linting & Analysis

bash
./gradlew lint                      # Run lint
./gradlew lintDebug                 # Debug only (faster)
./gradlew ktlintCheck               # Kotlin style (if configured)
./gradlew detekt                    # Detekt analysis (if configured)

Clean & Refresh

bash
./gradlew clean                     # Clean build
./gradlew clean assembleDebug       # Clean + build
./gradlew --refresh-dependencies    # Force dependency refresh
./gradlew --stop                    # Stop Gradle daemon

Dependencies

bash
./gradlew dependencies              # All dependencies
./gradlew app:dependencies          # Module dependencies
./gradlew dependencyInsight --dependency <name>

Signing

Debug keystore location:

  • Linux: ~/.android/debug.keystore
  • macOS: ~/.android/debug.keystore
  • Windows: C:\Users\<user>\.android\debug.keystore

Password: android, Alias: androiddebugkey

bash
# Create release keystore
keytool -genkey -v -keystore release.keystore \
    -alias my-key-alias -keyalg RSA -keysize 2048 -validity 10000

Performance

bash
./gradlew assembleDebug --parallel  # Parallel builds
./gradlew assembleDebug --build-cache  # Use cache
./gradlew assembleDebug --offline   # Offline mode
./gradlew --scan                    # Build scan (uploads data)
./gradlew --profile                 # Local profile report

gradle.properties Optimization

properties
org.gradle.jvmargs=-Xmx4g -XX:+HeapDumpOnOutOfMemoryError
org.gradle.parallel=true
org.gradle.caching=true
org.gradle.configuration-cache=true
android.useAndroidX=true

SDK Management

sdkmanager

bash
sdkmanager --list                   # List available packages
sdkmanager --list | grep system     # Filter system images
sdkmanager "platform-tools"         # Install package
sdkmanager "platforms;android-34"   # Install platform
sdkmanager "system-images;android-34;google_apis;x86_64"
sdkmanager --update                 # Update all
sdkmanager --licenses               # Accept licenses

avdmanager

bash
avdmanager list device              # List device profiles
avdmanager list avd                 # List created AVDs

# Create AVD
avdmanager create avd -n my_avd \
    -k "system-images;android-34;google_apis;x86_64" \
    -d pixel_6

avdmanager delete avd -n my_avd

Emulator CLI

bash
emulator -list-avds                 # List AVDs
emulator @my_avd                    # Start AVD
emulator @my_avd -no-snapshot       # Fresh boot
emulator @my_avd -no-window         # Headless
emulator @my_avd -wipe-data         # Factory reset

ROM Building (AOSP/LineageOS)

Environment Setup

bash
# Install repo tool
mkdir -p ~/.bin
curl https://storage.googleapis.com/git-repo-downloads/repo > ~/.bin/repo
chmod a+x ~/.bin/repo
export PATH="$HOME/.bin:$PATH"

# Initialize repo
mkdir android && cd android
repo init -u https://github.com/LineageOS/android.git -b lineage-21.0
# Or AOSP: repo init -u https://android.googlesource.com/platform/manifest

# Sync source
repo sync -c -j$(nproc) --force-sync --no-tags --no-clone-bundle

Build Commands

bash
# Setup environment
source build/envsetup.sh

# Select device
lunch <device>-userdebug           # AOSP
breakfast <device>                  # LineageOS

# Build
m                                   # Full build
mka bacon                           # LineageOS (with flashable zip)
mka bootimage                       # Just boot.img
mka systemimage                     # Just system

# Parallel build
m -j$(nproc)

Build Variants

VariantPurpose
userProduction, no root, limited debugging
userdebugLike user + root + debugging
engDevelopment, all debug tools

Common Targets

bash
m bootimage                         # Kernel + ramdisk
m systemimage                       # System partition
m vendorimage                       # Vendor partition
m otapackage                        # OTA zip
mka bacon                           # LineageOS flashable zip

# Module-specific
m Settings                          # Just Settings app
mm                                  # Build current directory
mmm packages/apps/Settings          # Build specific path

LineageOS Specifics

bash
breakfast <device>                  # Setup + sync device deps
brunch <device>                     # breakfast + mka bacon

# Cherry-pick from Gerrit
repopick <change_number>
repopick -t <topic>

# Sync specific project
repo sync packages/apps/Settings

Build Output

out/target/product/<device>/
├── boot.img                        # Kernel + ramdisk
├── system.img                      # System partition
├── vendor.img                      # Vendor partition
├── lineage-*.zip                   # Flashable zip (LineageOS)
└── recovery.img                    # Recovery (non-A/B)

Device Trees

Structure

device/<vendor>/<device>/
├── AndroidProducts.mk              # Product makefiles list
├── BoardConfig.mk                  # Board configuration
├── device.mk                       # Device makefile
├── lineage_<device>.mk             # LineageOS product
├── extract-files.sh                # Vendor blob extraction
├── proprietary-files.txt           # Blob list
├── sepolicy/                       # SELinux policies
└── overlay/                        # Resource overlays

Key Files

BoardConfig.mk - Hardware configuration:

makefile
TARGET_ARCH := arm64
TARGET_BOARD_PLATFORM := <platform>
TARGET_BOOTLOADER_BOARD_NAME := <device>
BOARD_KERNEL_CMDLINE := ...
BOARD_BOOT_HEADER_VERSION := 4

device.mk - Device packages:

makefile
PRODUCT_PACKAGES += \
    android.hardware.audio@7.0-impl \
    audio.primary.$(TARGET_BOARD_PLATFORM)

PRODUCT_COPY_FILES += \
    $(LOCAL_PATH)/configs/audio_policy.conf:...

Kernel Building

Standalone

bash
# Setup
export ARCH=arm64
export CROSS_COMPILE=aarch64-linux-gnu-
# Or for Clang:
export CC=clang
export CLANG_TRIPLE=aarch64-linux-gnu-

# Configure
make <device>_defconfig

# Build
make -j$(nproc)

# Output
arch/arm64/boot/Image.gz

In AOSP Tree

makefile
# In BoardConfig.mk
TARGET_KERNEL_SOURCE := kernel/<vendor>/<device>
TARGET_KERNEL_CONFIG := <device>_defconfig
TARGET_KERNEL_CLANG_COMPILE := true

Troubleshooting

Common Gradle Issues

bash
# OOM
export GRADLE_OPTS="-Xmx4g"

# Daemon issues
./gradlew --stop
rm -rf ~/.gradle/daemon

# Cache issues
./gradlew clean --refresh-dependencies

Common AOSP Issues

bash
# Ninja error - usually dependency issue
m clean && m

# Jack server (old builds)
./prebuilts/sdk/tools/jack-admin kill-server
./prebuilts/sdk/tools/jack-admin start-server

# SELinux issues
audit2allow -i audit.log

Build Logs

bash
# Gradle
./gradlew assembleDebug --stacktrace
./gradlew assembleDebug --info

# AOSP
m 2>&1 | tee build.log

Quick Reference

Gradle

TaskCommand
Build debug./gradlew assembleDebug
Build release./gradlew assembleRelease
Install./gradlew installDebug
Test./gradlew test
Lint./gradlew lint
Clean./gradlew clean
Dependencies./gradlew dependencies

AOSP/LineageOS

TaskCommand
Setup envsource build/envsetup.sh
Select devicelunch <device>-userdebug
Full buildm
LineageOS zipmka bacon
Just bootmka bootimage
Syncrepo sync -c -j$(nproc)

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Android Build AI skill do?

Use when building Android apps (Gradle CLI) or ROMs (AOSP, LineageOS). Triggers on "gradle build", "assemble", "AOSP", "LineageOS", "lunch", "mka", "breakfast", "brunch", "compile android", "device tree", "kernel build".

Why use Android Build on TypingMind?

Because you install it once and use it with any model. Android Build is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Android Build in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/hyperb1iss/hyperdroid-skill/tree/main/skills/android-build. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Android Build?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Android Build?

As many as you like. As long as a model supports skills, you can use Android Build with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Android Build AI skill free?

Yes. It is published on GitHub by hyperb1iss under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇