android-build-verification
Skill11 starsChanged 8 months agoMITView on GitHub
MANDATORY verification skill to run after EVERY file change. Automatically triggers an Android build (assembledDebug) to check for compilation or schema errors.
In this repository40 other files it gives its agents.
- .github/copilot-instructions.mdCopilot instructions
- android-accessibilitySkill
- android-adaptive-layoutsSkill
- android-adb-terminalSkill
- android-background-executionSkill
- android-bluetooth-bleSkill
- android-camerax-mlkitSkill
- android-ci-cd-expertSkill
- android-clean-architectureSkill
- android-code-review-expertSkill
- android-coroutines-expertSkill
- android-custom-drawing-canvasSkill
- android-design-system-m3Skill
- android-design-to-codeSkill
- android-detekt-expertSkill
- android-enterprise-securitySkill
- android-gemini-nanoSkill
- android-google-workspace-expertSkill
- android-gradle-expertSkill
- android-hardware-testingSkill
- android-jetpack-composeSkill
- android-kmp-compose-uiSkill
- android-kmp-platform-channelsSkill
- android-kmp-sharedSkill
- android-ktlint-formattingSkill
- android-lint-and-qualitySkill
- android-local-stt-ttsSkill
- android-location-mapsSkill
- android-macrobenchmarkSkill
- android-media3-exoplayerSkill
- android-media-and-image-expertSkill
- android-motion-animationsSkill
- android-navigation-expertSkill
- android-offline-firstSkill
- android-performance-auditSkill
- android-rag-localSkill
- android-screenshot-testingSkill
- android-security-hardenedSkill
- android-unit-testingSkill
- android-wear-os-composeSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
15 rules. About 0 are common, 5 are distinctive, and 10 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈5
Distinctive · estimate
This author's own choices. Worth a look.
10
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 23
After EVERY edit: After you modify more than 2 files or 20 lines of code.
- Very specific: line 24
Dependency Changes: After updating libs.versions.toml or build.gradle.kts.
- Very specific: line 25
DI/Schema Changes: After adding a new @HiltAndroidApp, @Entity, or @Dao.
- Very specific: line 26
Resource Changes: If you add new icons or strings to res/.
- Distinctive: line 33
Purpose: Verify that the entire project compiles.
- Distinctive: line 38
Purpose: Ensure that logic didn't regress after the build script was changed.
- Very specific: line 41
Hilt Entry Point: Verify that the Application class (annotated with @HiltAndroidApp) is registered in AndroidManifest.xml under …
- Very specific: line 42
Theme Bridge: If using Material 3 XML themes, ensure com.google.android.material:material is present in dependencies.
- Very specific: line 43
Icon Resources: Check that res/mipmap-anydpi-v26 and res/drawable contain valid XML vectors for adaptive icons to avoid AAPT linking errors.
- Distinctive: line 47
When explicitly tasked to create a project or scaffold a new feature from scratch, agents MUST verify these items before claiming …
- Very specific: line 61
"Unresolved Reference": Check imports or if the target module is missing from settings.gradle.kts.
- Very specific: line 62
"Duplicate Class": Check for version conflicts in libs.versions.toml.
- Very specific: line 63
"Hilt Error": Ensure the @AndroidEntryPoint or @Module classes have the correct annotations and that kapt is active.
- Very specific: line 64
"Room Schema Export": Verify if you moved database versioning without updating the exportSchema config.
- Distinctive: line 70
Step 3: If it fails, fix the code immediately.
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Android Build Verification 🛠️🔍
A foundational quality guard for Android AI Agents that ensures no code is committed or merged without a successful compilation.
⚡ When to Use
- After EVERY edit: After you modify more than 2 files or 20 lines of code.
- Dependency Changes: After updating
libs.versions.tomlorbuild.gradle.kts. - DI/Schema Changes: After adding a new
@HiltAndroidApp,@Entity, or@Dao. - Resource Changes: If you add new icons or strings to
res/.
🏗️ The Build Workflow
1. Fast Compilation Check
- Command:
./gradlew assembleDebug --parallel --build-cache - Purpose: Verify that the entire project compiles.
2. Unit Verification
- Command:
./gradlew testDebugUnitTest - Purpose: Ensure that logic didn't regress after the build script was changed.
3. Manifest & Resource Consistency (Critical)
- Hilt Entry Point: Verify that the
Applicationclass (annotated with@HiltAndroidApp) is registered inAndroidManifest.xmlunderandroid:name. - Theme Bridge: If using Material 3 XML themes, ensure
com.google.android.material:materialis present in dependencies. - Icon Resources: Check that
res/mipmap-anydpi-v26andres/drawablecontain valid XML vectors for adaptive icons to avoid AAPT linking errors.
🛑 Scaffolding / Empty Project Guardrails
When explicitly tasked to create a project or scaffold a new feature from scratch, agents MUST verify these items before claiming completion:
- Complete Theme Implementation: Did you actually create
Theme.kt,Color.kt, andType.kt? (PreventsTheme not founderrors). - Compose Compiler Symmetry: Did you double-check that the
composeCompilerversion explicitly matches thekotlinplugin version inlibs.versions.toml? - Auxiliary Dependencies: Did you add the required libraries you referenced? (e.g.
coil-compose,hilt-navigation-compose,windowsizeclass). - End-to-End Hookup: Are all UI buttons calling actual ViewModel methods that hit a Repository, or did you accidentally leave an empty
{ /* TODO */ }block? Do not leave disconnected UIs.
🚀 Performance Strategies
- Daemon Speed: Keep the Gradle daemon warm by running consecutive tasks.
- Offline Mode: If building frequently without dependency changes, use
--offlineto skip network checks. - Task Selection: If only one module changed (e.g.,
:feature:auth), only build that module:./gradlew :feature:auth:assembleDebug.
🧪 Error & Symptom Checker
- "Unresolved Reference": Check imports or if the target module is missing from
settings.gradle.kts. - "Duplicate Class": Check for version conflicts in
libs.versions.toml. - "Hilt Error": Ensure the
@AndroidEntryPointor@Moduleclasses have the correct annotations and thatkaptis active. - "Room Schema Export": Verify if you moved database versioning without updating the
exportSchemaconfig.
📐 Continuous Verification Workflow (For Agents)
- Step 1: Make the intended change.
- Step 2: Run
./gradlew assembleDebug. - Step 3: If it fails, fix the code immediately.
- Step 4: Report "Build Successful" alongside the code changes to the user.
📜 Checklist for Reliability
- Local Build: Did it pass locally before saying "I'm done"?
- Syncing: Did you run
git add .and commit the new files for the user? - Lint: Are there no critical lint errors that would prevent a release?
🔗 Related Resources
- Detekt Expert Skill
- Unit Testing Skill
- Gradle Expert Skill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

