Creator · new-silvermoon
Last updated · Sep 2, 2026
Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating CI/CD performance, analyzing build scans, or identifying compilation bottlenecks.
Creator · new-silvermoon
Last updated · Sep 2, 2026
Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating CI/CD performance, analyzing build scans, or identifying compilation bottlenecks.
Creator · new-silvermoon
Last updated · Sep 2, 2026
Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating CI/CD performance, analyzing build scans, or identifying compilation bottlenecks.
Creator · new-silvermoon
Last updated · Sep 2, 2026
Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating CI/CD performance, analyzing build scans, or identifying compilation bottlenecks.
Sandbox only
Install targets
Codex install prompt
Install the "gradle-build-performance" agent skill from https://github.com/new-silvermoon/awesome-android-agent-skills/tree/main/.github/skills/performance/gradle-build-performance. Read its SKILL.md or equivalent instructions first, install only the files needed for this workspace, and summarize any required setup before using it. Skill purpose: Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating CI/CD performance, analyzing build scans, or identifying compilation bottlenecks. After the install attempt, report the result to https://www.openagentskill.com/api/agent/outcome with POST JSON {"event_id":"install_<unique-id>","skill_slug":"new-silvermoon-gradle-build-performance","task":"Install gradle-build-performance","agent":"codex","outcome":"success","install_used":true}. Replace event_id with a unique value and outcome with success or failed. Report success only after the skill is installed and a minimal verification passes.Supply asset profile
Code review, repo analysis, testing, CI, GitHub, DevOps, and developer workflow skills.
Scenario
Coding agents
I need a coding agent that can understand a repository, edit code, and review pull requests.
Agent fit
Claude Code + CLI + Codex
Codex, Claude Code, Cursor, CLI, or custom agents.
Install
Ready
npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performance
Maintenance
active
1mo since push
Risk
Needs review
Permission surface may require sandboxing
GitHub quality
948
70/100 Quality · 76/100 Trust
Coverage tags
Review notes
Permission surface may require sandboxing · Quality score needs review
Agent adoption scorecard
These scores combine public repository metadata, OpenAgentSkill review signals, maintenance freshness, and install readiness. They are a shortlist signal, not a replacement for human review.
Quality
StrongSolid option that is likely worth shortlisting for production workflows.
Trust
Sandbox onlyUseful candidate with missing or mixed trust signals. Keep it in an isolated workspace until the outcome loop proves task fit.
Audit
Needs reviewA machine-readable review of install readiness, security metadata, maintenance, and adoption risk.
OpenAgentSkill Trust Score v5
Run only in a sandbox and compare close alternatives before using it for real work.
Stars
948 GitHub stars
Repo activity
948 stars, 94 forks
Maintenance
1mo since push
License
Apache-2.0
Install
npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performance
Install safety
Agent-readable metadata
Use this block or the embedded JSON to decide whether an agent should install this skill, choose an alternative, or ask for human review first.
Suited tasks
Suited agents
Install decision
Trust and risk
Outcome loop
Install command
npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performanceDo not use when
Alternative
174.2K Stars
npx skills add anthropics/skills --skill frontend-design
Alternative
84.4K Stars
npx skills add Leonxlnx/taste-skill --skill design-taste-frontend
Alternative
174.2K Stars
npx skills add anthropics/skills --skill canvas-design
Alternative
174.2K Stars
npx skills add anthropics/skills --skill brand-guidelines
Agent safety v2
Sparse or mixed signals. Useful for discovery, but not for autonomous installation.
Test manually in an isolated workspace and compare against safer alternatives.
high
Skill metadata references terminal, CLI, shell, subprocess, or command execution workflows.
medium
Skill likely fetches remote pages, APIs, repositories, or external services.
medium
Skill may read or write project files, documents, generated artifacts, or local workspace state.
Agent resolve plan
The Resolve API returns the selected skill, alternatives, safety policy, audit notes, install target, and copy-paste prompt an agent can follow without scraping this page.
Open JSON
/api/agent/resolve?task=Use%20gradle-build-performance%20for%20an%20agent%20workflow&agent=codex&max_risk=medium
Resolve text
/api/agent/resolve?task=Use%20gradle-build-performance%20for%20an%20agent%20workflow&agent=codex&max_risk=medium&format=text
Install handoff
/api/skills/new-silvermoon-gradle-build-performance/install
Agent should check
Copy prompt
Task: Use gradle-build-performance in this workspace.
Resolve first: https://www.openagentskill.com/api/agent/resolve?task=Use%20gradle-build-performance%20for%20an%20agent%20workflow&agent=codex&max_risk=medium
Review install handoff: https://www.openagentskill.com/api/skills/new-silvermoon-gradle-build-performance/install
Install command: npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performance
Before running it, summarize audit warnings, required permissions, and the fallback skill if install is risky.Agent handoff
Use the public install endpoint to fetch the command, safety checklist, target prompts, and canonical links for this skill.
Install handoff
/api/skills/new-silvermoon-gradle-build-performance/install
LLM text format
/api/skills/new-silvermoon-gradle-build-performance/install?format=text
Find alternatives
/api/skills/search?q=gradle-build-performance&limit=3
Agent prompt
Use gradle-build-performance for this task. Review https://www.openagentskill.com/api/skills/new-silvermoon-gradle-build-performance/install, then install with: npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performanceRegistry metadata
This page exposes the same decision, trust, audit, use-case, and install signals through the Registry API, so agents can rank this skill without scraping the UI.
Manifest
/api/registry/manifest/new-silvermoon-gradle-build-performance
LLM text
/api/registry/manifest/new-silvermoon-gradle-build-performance?format=text
Install alias
/api/registry/install/new-silvermoon-gradle-build-performance
Recommend
/api/registry/recommend?task=Use%20gradle-build-performance%20in%20an%20agent%20workflow&limit=3
Agent fit
Research agents
Use-case tags
Platforms
Claude Code
Audit report
A machine-readable review of install readiness, security metadata, maintenance, and adoption risk.
Agent decision cockpit
Shortlist this skill and compare it with close alternatives before production adoption.
Role in stack
Companion skill
Primary fit
Research agents
Trust label
Strong shortlist
Install path
Command ready
Use when
Evidence
review first
Implementation path
Trust profile
Useful candidate with missing or mixed trust signals. Keep it in an isolated workspace until the outcome loop proves task fit.
GitHub adoption
INFO948 GitHub stars
Stars/forks activity
INFO948 stars, 94 forks; issue activity unavailable in current metadata
Recent maintenance
PASS1mo since push
License clarity
PASSApache-2.0
Good signals
Review before install
Recommended action
Run only in a sandbox and compare close alternatives before using it for real work.
Quality profile
Solid option that is likely worth shortlisting for production workflows.
Workflow fit
Investigate faster
I need my agent to research a topic, compare sources, and produce a concise report.
Operate local tools
I need my agent to operate local files and desktop apps in a repeatable workflow.
Build and ship code
I need a coding agent that can understand a repository, edit code, and review pull requests.
Workflow fit
Turn skills into distribution
A workflow for turning newly indexed skills into SEO briefs, social drafts, comparison pages, and reusable publishing workflows.
Find, compare, and synthesize
A workflow for agents that gather sources, compare claims, summarize long material, and draft useful research briefs.
Inspect, patch, and verify code
A workflow for software agents that inspect repositories, review pull requests, generate tests, and turn findings into shippable patches.
Alternative shortlist
Similar skills that may fit this task.
Guidance for distinctive, intentional UI design, typography, visual direction, and non-template-like product interfaces.
Design and implementation guidance for distinctive landing pages, portfolios, product demos, and purposeful redesigns.
Create original visual art, posters, PNG assets, and PDF documents through a clear design philosophy.
Apply Anthropic official brand colors, typography, and visual standards to appropriate Anthropic-related artifacts.
--- name: gradle-build-performance description: Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating CI/CD performance, analyzing build scans, or identifying compilation bottlenecks. ---
# Gradle Build Performance
## When to Use
- Build times are slow (clean or incremental) - Investigating build performance regressions - Analyzing Gradle Build Scans - Identifying configuration vs execution bottlenecks - Optimizing CI/CD build times - Enabling Gradle Configuration Cache - Reducing unnecessary recompilation - Debugging kapt/KSP annotation processing
## Example Prompts
- "My builds are slow, how can I speed them up?" - "How do I analyze a Gradle build scan?" - "Why is configuration taking so long?" - "Why does my project always recompile everything?" - "How do I enable configuration cache?" - "Why is kapt so slow?"
---
## Workflow
1. **Measure Baseline** — Clean build + incremental build times 2. **Generate Build Scan** — `./gradlew assembleDebug --scan` 3. **Identify Phase** — Configuration? Execution? Dependency resolution? 4. **Apply ONE optimization** — Don't batch changes 5. **Measure Improvement** — Compare against baseline 6. **Verify in Build Scan** — Visual confirmation
---
## Quick Diagnostics
### Generate Build Scan
```bash ./gradlew assembleDebug --scan ```
### Profile Build Locally
```bash ./gradlew assembleDebug --profile # Opens report in build/reports/profile/ ```
### Build Timing Summary
```bash ./gradlew assembleDebug --info | grep -E "^\:.*" # Or view in Android Studio: Build > Analyze APK Build ```
---
## Build Phases
| Phase | What Happens | Common Issues | |-------|--------------|---------------| | **Initialization** | `settings.gradle.kts` evaluated | Too many `include()` statements | | **Configuration** | All `build.gradle.kts` files evaluated | Expensive plugins, eager task creation | | **Execution** | Tasks run based on inputs/outputs | Cache misses, non-incremental tasks |
### Identify the Bottleneck
``` Build scan → Performance → Build timeline ```
- **Long configuration phase**: Focus on plugin and buildscript optimization - **Long execution phase**: Focus on task caching and parallelization - **Dependency resolution slow**: Focus on repository configuration
---
## 12 Optimization Patterns
### 1. Enable Configuration Cache
Caches configuration phase across builds (AGP 8.0+):
```properties # gradle.properties org.gradle.configuration-cache=true org.gradle.configuration-cache.problems=warn ```
### 2. Enable Build Cache
Reuses task outputs across builds and machines:
```properties # gradle.properties org.gradle.caching=true ```
### 3. Enable Parallel Execution
Build independent modules simultaneously:
```properties # gradle.properties org.gradle.parallel=true ```
### 4. Increase JVM Heap
Allocate more memory for large projects:
```properties # gradle.properties org.gradle.jvmargs=-Xmx4g -XX:+UseParallelGC ```
### 5. Use Non-Transitive R Classes
Reduces R class size and compilation (AGP 8.0+ default):
```properties # gradle.properties android.nonTransitiveRClass=true ```
### 6. Migrate kapt to KSP
KSP is 2x faster than kapt for Kotlin:
```kotlin // Before (slow) kapt("com.google.dagger:hilt-compiler:2.51.1")
// After (fast) ksp("com.google.dagger:hilt-compiler:2.51.1") ```
### 7. Avoid Dynamic Dependencies
Pin dependency versions:
```kotlin // BAD: Forces resolution every build implementation("com.example:lib:+") implementation("com.example:lib:1.0.+")
// GOOD: Fixed version implementation("com.example:lib:1.2.3") ```
### 8. Optimize Repository Order
Put most-used repositories first:
```kotlin // settings.gradle.kts dependencyResolutionManagement { repositories { google() // First: Android dependencies mavenCentral() // Second: Most libraries // Third-party repos last } } ```
### 9. Use includeBuild for Local Modules
Composite builds are faster than `project()` for large monorepos:
```kotlin // settings.gradle.kts includeBuild("shared-library") { dependencySubstitution { substitute(module("com.example:shared")).using(project(":")) } } ```
### 10. Enable Incremental Annotation Processing
```properties # gradle.properties kapt.incremental.apt=true kapt.use.worker.api=true ```
### 11. Avoid Configuration-Time I/O
Don't read files or make network calls during configuration:
```kotlin // BAD: Runs during configuration val version = file("version.txt").readText()
// GOOD: Defer to execution val version = providers.fileContents(file("version.txt")).asText ```
### 12. Use Lazy Task Configuration
Avoid `create()`, use `register()`:
```kotlin // BAD: Eagerly configured tasks.create("myTask") { ... }
// GOOD: Lazily configured tasks.register("myTask") { ... } ```
---
## Common Bottleneck Analysis
### Slow Configuration Phase
**Symptoms**: Build scan shows long "Configuring build" time
**Causes & Fixes**: | Cause | Fix | |-------|-----| | Eager task creation | Use `tasks.register()` instead of `tasks.create()` | | buildSrc with many dependencies | Migrate to Convention Plugins with `includeBuild` | | File I/O in build scripts | Use `providers.fileContents()` | | Network calls in plugins | Cache results or use offline mode |
### Slow Compilation
**Symptoms**: `:app:compileDebugKotlin` takes too long
**Causes & Fixes**: | Cause | Fix | |-------|-----| | Non-incremental changes | Avoid `build.gradle.kts` changes that invalidate cache | | Large modules | Break into smaller feature modules | | Excessive kapt usage | Migrate to KSP | | Kotlin compiler memory | Increase `kotlin.daemon.jvmargs` |
### Cache Misses
**Symptoms**: Tasks always rerun despite no changes
**Causes & Fixes**: | Cause | Fix | |-------|-----| | Unstable task inputs | Use `@PathSensitive`, `@NormalizeLineEndings` | | Absolute paths in outputs | Use relative paths | | Missing `@CacheableTask` | Add annotation to custom tasks | | Different JDK versions | Standardize JDK across environments |
---
## CI/CD Optimizations
### Remote Build Cache
```kotlin // settings.gradle.kts buildCache { local { isEnabled = true } remote<HttpBuildCache> { url = uri("https://cache.example.com/") isPush = System.getenv("CI") == "true" credentials { username = System.getenv("CACHE_USER") password = System.getenv("CACHE_PASS") } } } ```
### Gradle Enterprise / Develocity
For advanced build analytics:
```kotlin // settings.gradle.kts plugins { id("com.gradle.develocity") version "3.17" }
develocity { buildScan { termsOfUseUrl.set("https://gradle.com/help/legal-terms-of-use") termsOfUseAgree.set("yes") publishing.onlyIf { System.getenv("CI") != null } } } ```
### Skip Unnecessary Tasks in CI
```bash # Skip tests for UI-only changes ./gradlew assembleDebug -x test -x lint
# Only run affected module tests ./gradlew :feature:login:test ```
---
## Android Studio Settings
### File → Settings → Build → Gradle
- **Gradle JDK**: Match your project's JDK - **Build and run using**: Gradle (not IntelliJ) - **Run tests using**: Gradle
### File → Settings → Build → Compiler
- **Compile independent modules in parallel**: ✅ Enabled - **Configure on demand**: ❌ Disabled (deprecated)
---
## Verification Checklist
After optimizations, verify:
- [ ] Configuration cache enabled and working - [ ] Build cache hit rate > 80% (check build scan) - [ ] No dynamic dependency versions - [ ] KSP used instead of kapt where possible - [ ] Parallel execution enabled - [ ] JVM memory tuned appropriately - [ ] CI remote cache configured - [ ] No configuration-time I/O
---
## References
- [Optimize Build Speed](https://developer.android.com/build/optimize-your-build) - [Gradle Configuration Cache](https://docs.gradle.org/current/userguide/configuration_cache.html) - [Gradle Build Cache](https://docs.gradle.org/current/userguide/build_cache.html) - [Migrate from kapt to KSP](https://developer.android.com/build/migrate-to-ksp) - [Gradle Build Scans](https://scans.gradle.com/)
Source provenance
Decision snapshot
948 GitHub stars
Audit
Install and adoption review
Agent-proven evidence
Outcome reports after resolve, review, install, and one narrow run.
No agent outcome data yet. The first agent run can report success, setup needs, risk blocks, failure, or not-relevant through /api/agent/outcome.
Install
Free and open source. Review the report before installing into production agents.
Growth loop
Scenario-led draft for gradle-build-performance, ready for a manual X post.
gradle-build-performance: Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating... 948 stars https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=x
Listing + install path for gradle-build-performance: https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=x Install: npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-p...
Listing source
This listing was indexed from public sources and is not marked official until a maintainer claim is approved.
Attribution links to the public repository or creator profile. Creators can claim the listing to update ownership signals.
Claim this skillOwner claim
This Registry indexed listing is attributed to new-silvermoon but is not marked official yet. Claim it to add a verified owner signal and make future launch, install, and audit updates easier to trust.
Creator backlink kit
Show the canonical listing, current trust and audit signals, and real Agent-Proven evidence where developers evaluate the repository.
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance/audit)
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)new-silvermoon
@new-silvermoon
Share whether this skill looks useful for your agent workflow. Aggregated feedback improves rankings over time.
Sandbox only
Frontend Design
Guidance for distinctive, intentional UI design, typography, visual direction, and non-template-like product interfaces.
174.2K StarsTaste Skill: Anti-Slop Frontend
Design and implementation guidance for distinctive landing pages, portfolios, product demos, and purposeful redesigns.
84.4K StarsCanvas Design
Create original visual art, posters, PNG assets, and PDF documents through a clear design philosophy.
174.2K StarsAnthropic Brand Guidelines
Apply Anthropic official brand colors, typography, and visual standards to appropriate Anthropic-related artifacts.
174.2K StarsSandbox only
Install targets
Codex install prompt
Install the "gradle-build-performance" agent skill from https://github.com/new-silvermoon/awesome-android-agent-skills/tree/main/.github/skills/performance/gradle-build-performance. Read its SKILL.md or equivalent instructions first, install only the files needed for this workspace, and summarize any required setup before using it. Skill purpose: Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating CI/CD performance, analyzing build scans, or identifying compilation bottlenecks. After the install attempt, report the result to https://www.openagentskill.com/api/agent/outcome with POST JSON {"event_id":"install_<unique-id>","skill_slug":"new-silvermoon-gradle-build-performance","task":"Install gradle-build-performance","agent":"codex","outcome":"success","install_used":true}. Replace event_id with a unique value and outcome with success or failed. Report success only after the skill is installed and a minimal verification passes.Supply asset profile
Code review, repo analysis, testing, CI, GitHub, DevOps, and developer workflow skills.
Scenario
Coding agents
I need a coding agent that can understand a repository, edit code, and review pull requests.
Agent fit
Claude Code + CLI + Codex
Codex, Claude Code, Cursor, CLI, or custom agents.
Install
Ready
npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performance
Maintenance
active
1mo since push
Risk
Needs review
Permission surface may require sandboxing
GitHub quality
948
70/100 Quality · 76/100 Trust
Coverage tags
Review notes
Permission surface may require sandboxing · Quality score needs review
Agent adoption scorecard
These scores combine public repository metadata, OpenAgentSkill review signals, maintenance freshness, and install readiness. They are a shortlist signal, not a replacement for human review.
Quality
StrongSolid option that is likely worth shortlisting for production workflows.
Trust
Sandbox onlyUseful candidate with missing or mixed trust signals. Keep it in an isolated workspace until the outcome loop proves task fit.
Audit
Needs reviewA machine-readable review of install readiness, security metadata, maintenance, and adoption risk.
OpenAgentSkill Trust Score v5
Run only in a sandbox and compare close alternatives before using it for real work.
Stars
948 GitHub stars
Repo activity
948 stars, 94 forks
Maintenance
1mo since push
License
Apache-2.0
Install
npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performance
Install safety
Agent-readable metadata
Use this block or the embedded JSON to decide whether an agent should install this skill, choose an alternative, or ask for human review first.
Suited tasks
Suited agents
Install decision
Trust and risk
Outcome loop
Install command
npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performanceDo not use when
Alternative
174.2K Stars
npx skills add anthropics/skills --skill frontend-design
Alternative
84.4K Stars
npx skills add Leonxlnx/taste-skill --skill design-taste-frontend
Alternative
174.2K Stars
npx skills add anthropics/skills --skill canvas-design
Alternative
174.2K Stars
npx skills add anthropics/skills --skill brand-guidelines
Agent safety v2
Sparse or mixed signals. Useful for discovery, but not for autonomous installation.
Test manually in an isolated workspace and compare against safer alternatives.
high
Skill metadata references terminal, CLI, shell, subprocess, or command execution workflows.
medium
Skill likely fetches remote pages, APIs, repositories, or external services.
medium
Skill may read or write project files, documents, generated artifacts, or local workspace state.
Agent resolve plan
The Resolve API returns the selected skill, alternatives, safety policy, audit notes, install target, and copy-paste prompt an agent can follow without scraping this page.
Open JSON
/api/agent/resolve?task=Use%20gradle-build-performance%20for%20an%20agent%20workflow&agent=codex&max_risk=medium
Resolve text
/api/agent/resolve?task=Use%20gradle-build-performance%20for%20an%20agent%20workflow&agent=codex&max_risk=medium&format=text
Install handoff
/api/skills/new-silvermoon-gradle-build-performance/install
Agent should check
Copy prompt
Task: Use gradle-build-performance in this workspace.
Resolve first: https://www.openagentskill.com/api/agent/resolve?task=Use%20gradle-build-performance%20for%20an%20agent%20workflow&agent=codex&max_risk=medium
Review install handoff: https://www.openagentskill.com/api/skills/new-silvermoon-gradle-build-performance/install
Install command: npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performance
Before running it, summarize audit warnings, required permissions, and the fallback skill if install is risky.Agent handoff
Use the public install endpoint to fetch the command, safety checklist, target prompts, and canonical links for this skill.
Install handoff
/api/skills/new-silvermoon-gradle-build-performance/install
LLM text format
/api/skills/new-silvermoon-gradle-build-performance/install?format=text
Find alternatives
/api/skills/search?q=gradle-build-performance&limit=3
Agent prompt
Use gradle-build-performance for this task. Review https://www.openagentskill.com/api/skills/new-silvermoon-gradle-build-performance/install, then install with: npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performanceRegistry metadata
This page exposes the same decision, trust, audit, use-case, and install signals through the Registry API, so agents can rank this skill without scraping the UI.
Manifest
/api/registry/manifest/new-silvermoon-gradle-build-performance
LLM text
/api/registry/manifest/new-silvermoon-gradle-build-performance?format=text
Install alias
/api/registry/install/new-silvermoon-gradle-build-performance
Recommend
/api/registry/recommend?task=Use%20gradle-build-performance%20in%20an%20agent%20workflow&limit=3
Agent fit
Research agents
Use-case tags
Platforms
Claude Code
Audit report
A machine-readable review of install readiness, security metadata, maintenance, and adoption risk.
Agent decision cockpit
Shortlist this skill and compare it with close alternatives before production adoption.
Role in stack
Companion skill
Primary fit
Research agents
Trust label
Strong shortlist
Install path
Command ready
Use when
Evidence
review first
Implementation path
Trust profile
Useful candidate with missing or mixed trust signals. Keep it in an isolated workspace until the outcome loop proves task fit.
GitHub adoption
INFO948 GitHub stars
Stars/forks activity
INFO948 stars, 94 forks; issue activity unavailable in current metadata
Recent maintenance
PASS1mo since push
License clarity
PASSApache-2.0
Good signals
Review before install
Recommended action
Run only in a sandbox and compare close alternatives before using it for real work.
Quality profile
Solid option that is likely worth shortlisting for production workflows.
Workflow fit
Investigate faster
I need my agent to research a topic, compare sources, and produce a concise report.
Operate local tools
I need my agent to operate local files and desktop apps in a repeatable workflow.
Build and ship code
I need a coding agent that can understand a repository, edit code, and review pull requests.
Workflow fit
Turn skills into distribution
A workflow for turning newly indexed skills into SEO briefs, social drafts, comparison pages, and reusable publishing workflows.
Find, compare, and synthesize
A workflow for agents that gather sources, compare claims, summarize long material, and draft useful research briefs.
Inspect, patch, and verify code
A workflow for software agents that inspect repositories, review pull requests, generate tests, and turn findings into shippable patches.
Alternative shortlist
Similar skills that may fit this task.
Guidance for distinctive, intentional UI design, typography, visual direction, and non-template-like product interfaces.
Design and implementation guidance for distinctive landing pages, portfolios, product demos, and purposeful redesigns.
Create original visual art, posters, PNG assets, and PDF documents through a clear design philosophy.
Apply Anthropic official brand colors, typography, and visual standards to appropriate Anthropic-related artifacts.
--- name: gradle-build-performance description: Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating CI/CD performance, analyzing build scans, or identifying compilation bottlenecks. ---
# Gradle Build Performance
## When to Use
- Build times are slow (clean or incremental) - Investigating build performance regressions - Analyzing Gradle Build Scans - Identifying configuration vs execution bottlenecks - Optimizing CI/CD build times - Enabling Gradle Configuration Cache - Reducing unnecessary recompilation - Debugging kapt/KSP annotation processing
## Example Prompts
- "My builds are slow, how can I speed them up?" - "How do I analyze a Gradle build scan?" - "Why is configuration taking so long?" - "Why does my project always recompile everything?" - "How do I enable configuration cache?" - "Why is kapt so slow?"
---
## Workflow
1. **Measure Baseline** — Clean build + incremental build times 2. **Generate Build Scan** — `./gradlew assembleDebug --scan` 3. **Identify Phase** — Configuration? Execution? Dependency resolution? 4. **Apply ONE optimization** — Don't batch changes 5. **Measure Improvement** — Compare against baseline 6. **Verify in Build Scan** — Visual confirmation
---
## Quick Diagnostics
### Generate Build Scan
```bash ./gradlew assembleDebug --scan ```
### Profile Build Locally
```bash ./gradlew assembleDebug --profile # Opens report in build/reports/profile/ ```
### Build Timing Summary
```bash ./gradlew assembleDebug --info | grep -E "^\:.*" # Or view in Android Studio: Build > Analyze APK Build ```
---
## Build Phases
| Phase | What Happens | Common Issues | |-------|--------------|---------------| | **Initialization** | `settings.gradle.kts` evaluated | Too many `include()` statements | | **Configuration** | All `build.gradle.kts` files evaluated | Expensive plugins, eager task creation | | **Execution** | Tasks run based on inputs/outputs | Cache misses, non-incremental tasks |
### Identify the Bottleneck
``` Build scan → Performance → Build timeline ```
- **Long configuration phase**: Focus on plugin and buildscript optimization - **Long execution phase**: Focus on task caching and parallelization - **Dependency resolution slow**: Focus on repository configuration
---
## 12 Optimization Patterns
### 1. Enable Configuration Cache
Caches configuration phase across builds (AGP 8.0+):
```properties # gradle.properties org.gradle.configuration-cache=true org.gradle.configuration-cache.problems=warn ```
### 2. Enable Build Cache
Reuses task outputs across builds and machines:
```properties # gradle.properties org.gradle.caching=true ```
### 3. Enable Parallel Execution
Build independent modules simultaneously:
```properties # gradle.properties org.gradle.parallel=true ```
### 4. Increase JVM Heap
Allocate more memory for large projects:
```properties # gradle.properties org.gradle.jvmargs=-Xmx4g -XX:+UseParallelGC ```
### 5. Use Non-Transitive R Classes
Reduces R class size and compilation (AGP 8.0+ default):
```properties # gradle.properties android.nonTransitiveRClass=true ```
### 6. Migrate kapt to KSP
KSP is 2x faster than kapt for Kotlin:
```kotlin // Before (slow) kapt("com.google.dagger:hilt-compiler:2.51.1")
// After (fast) ksp("com.google.dagger:hilt-compiler:2.51.1") ```
### 7. Avoid Dynamic Dependencies
Pin dependency versions:
```kotlin // BAD: Forces resolution every build implementation("com.example:lib:+") implementation("com.example:lib:1.0.+")
// GOOD: Fixed version implementation("com.example:lib:1.2.3") ```
### 8. Optimize Repository Order
Put most-used repositories first:
```kotlin // settings.gradle.kts dependencyResolutionManagement { repositories { google() // First: Android dependencies mavenCentral() // Second: Most libraries // Third-party repos last } } ```
### 9. Use includeBuild for Local Modules
Composite builds are faster than `project()` for large monorepos:
```kotlin // settings.gradle.kts includeBuild("shared-library") { dependencySubstitution { substitute(module("com.example:shared")).using(project(":")) } } ```
### 10. Enable Incremental Annotation Processing
```properties # gradle.properties kapt.incremental.apt=true kapt.use.worker.api=true ```
### 11. Avoid Configuration-Time I/O
Don't read files or make network calls during configuration:
```kotlin // BAD: Runs during configuration val version = file("version.txt").readText()
// GOOD: Defer to execution val version = providers.fileContents(file("version.txt")).asText ```
### 12. Use Lazy Task Configuration
Avoid `create()`, use `register()`:
```kotlin // BAD: Eagerly configured tasks.create("myTask") { ... }
// GOOD: Lazily configured tasks.register("myTask") { ... } ```
---
## Common Bottleneck Analysis
### Slow Configuration Phase
**Symptoms**: Build scan shows long "Configuring build" time
**Causes & Fixes**: | Cause | Fix | |-------|-----| | Eager task creation | Use `tasks.register()` instead of `tasks.create()` | | buildSrc with many dependencies | Migrate to Convention Plugins with `includeBuild` | | File I/O in build scripts | Use `providers.fileContents()` | | Network calls in plugins | Cache results or use offline mode |
### Slow Compilation
**Symptoms**: `:app:compileDebugKotlin` takes too long
**Causes & Fixes**: | Cause | Fix | |-------|-----| | Non-incremental changes | Avoid `build.gradle.kts` changes that invalidate cache | | Large modules | Break into smaller feature modules | | Excessive kapt usage | Migrate to KSP | | Kotlin compiler memory | Increase `kotlin.daemon.jvmargs` |
### Cache Misses
**Symptoms**: Tasks always rerun despite no changes
**Causes & Fixes**: | Cause | Fix | |-------|-----| | Unstable task inputs | Use `@PathSensitive`, `@NormalizeLineEndings` | | Absolute paths in outputs | Use relative paths | | Missing `@CacheableTask` | Add annotation to custom tasks | | Different JDK versions | Standardize JDK across environments |
---
## CI/CD Optimizations
### Remote Build Cache
```kotlin // settings.gradle.kts buildCache { local { isEnabled = true } remote<HttpBuildCache> { url = uri("https://cache.example.com/") isPush = System.getenv("CI") == "true" credentials { username = System.getenv("CACHE_USER") password = System.getenv("CACHE_PASS") } } } ```
### Gradle Enterprise / Develocity
For advanced build analytics:
```kotlin // settings.gradle.kts plugins { id("com.gradle.develocity") version "3.17" }
develocity { buildScan { termsOfUseUrl.set("https://gradle.com/help/legal-terms-of-use") termsOfUseAgree.set("yes") publishing.onlyIf { System.getenv("CI") != null } } } ```
### Skip Unnecessary Tasks in CI
```bash # Skip tests for UI-only changes ./gradlew assembleDebug -x test -x lint
# Only run affected module tests ./gradlew :feature:login:test ```
---
## Android Studio Settings
### File → Settings → Build → Gradle
- **Gradle JDK**: Match your project's JDK - **Build and run using**: Gradle (not IntelliJ) - **Run tests using**: Gradle
### File → Settings → Build → Compiler
- **Compile independent modules in parallel**: ✅ Enabled - **Configure on demand**: ❌ Disabled (deprecated)
---
## Verification Checklist
After optimizations, verify:
- [ ] Configuration cache enabled and working - [ ] Build cache hit rate > 80% (check build scan) - [ ] No dynamic dependency versions - [ ] KSP used instead of kapt where possible - [ ] Parallel execution enabled - [ ] JVM memory tuned appropriately - [ ] CI remote cache configured - [ ] No configuration-time I/O
---
## References
- [Optimize Build Speed](https://developer.android.com/build/optimize-your-build) - [Gradle Configuration Cache](https://docs.gradle.org/current/userguide/configuration_cache.html) - [Gradle Build Cache](https://docs.gradle.org/current/userguide/build_cache.html) - [Migrate from kapt to KSP](https://developer.android.com/build/migrate-to-ksp) - [Gradle Build Scans](https://scans.gradle.com/)
Source provenance
Decision snapshot
948 GitHub stars
Audit
Install and adoption review
Agent-proven evidence
Outcome reports after resolve, review, install, and one narrow run.
No agent outcome data yet. The first agent run can report success, setup needs, risk blocks, failure, or not-relevant through /api/agent/outcome.
Install
Free and open source. Review the report before installing into production agents.
Growth loop
Scenario-led draft for gradle-build-performance, ready for a manual X post.
gradle-build-performance: Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating... 948 stars https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=x
Listing + install path for gradle-build-performance: https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=x Install: npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-p...
Listing source
This listing was indexed from public sources and is not marked official until a maintainer claim is approved.
Attribution links to the public repository or creator profile. Creators can claim the listing to update ownership signals.
Claim this skillOwner claim
This Registry indexed listing is attributed to new-silvermoon but is not marked official yet. Claim it to add a verified owner signal and make future launch, install, and audit updates easier to trust.
Creator backlink kit
Show the canonical listing, current trust and audit signals, and real Agent-Proven evidence where developers evaluate the repository.
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance/audit)
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)new-silvermoon
@new-silvermoon
Share whether this skill looks useful for your agent workflow. Aggregated feedback improves rankings over time.
Sandbox only
Frontend Design
Guidance for distinctive, intentional UI design, typography, visual direction, and non-template-like product interfaces.
174.2K StarsTaste Skill: Anti-Slop Frontend
Design and implementation guidance for distinctive landing pages, portfolios, product demos, and purposeful redesigns.
84.4K StarsCanvas Design
Create original visual art, posters, PNG assets, and PDF documents through a clear design philosophy.
174.2K StarsAnthropic Brand Guidelines
Apply Anthropic official brand colors, typography, and visual standards to appropriate Anthropic-related artifacts.
174.2K StarsSandbox only
Install targets
Codex install prompt
Install the "gradle-build-performance" agent skill from https://github.com/new-silvermoon/awesome-android-agent-skills/tree/main/.github/skills/performance/gradle-build-performance. Read its SKILL.md or equivalent instructions first, install only the files needed for this workspace, and summarize any required setup before using it. Skill purpose: Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating CI/CD performance, analyzing build scans, or identifying compilation bottlenecks. After the install attempt, report the result to https://www.openagentskill.com/api/agent/outcome with POST JSON {"event_id":"install_<unique-id>","skill_slug":"new-silvermoon-gradle-build-performance","task":"Install gradle-build-performance","agent":"codex","outcome":"success","install_used":true}. Replace event_id with a unique value and outcome with success or failed. Report success only after the skill is installed and a minimal verification passes.Supply asset profile
Code review, repo analysis, testing, CI, GitHub, DevOps, and developer workflow skills.
Scenario
Coding agents
I need a coding agent that can understand a repository, edit code, and review pull requests.
Agent fit
Claude Code + CLI + Codex
Codex, Claude Code, Cursor, CLI, or custom agents.
Install
Ready
npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performance
Maintenance
active
1mo since push
Risk
Needs review
Permission surface may require sandboxing
GitHub quality
948
70/100 Quality · 76/100 Trust
Coverage tags
Review notes
Permission surface may require sandboxing · Quality score needs review
Agent adoption scorecard
These scores combine public repository metadata, OpenAgentSkill review signals, maintenance freshness, and install readiness. They are a shortlist signal, not a replacement for human review.
Quality
StrongSolid option that is likely worth shortlisting for production workflows.
Trust
Sandbox onlyUseful candidate with missing or mixed trust signals. Keep it in an isolated workspace until the outcome loop proves task fit.
Audit
Needs reviewA machine-readable review of install readiness, security metadata, maintenance, and adoption risk.
OpenAgentSkill Trust Score v5
Run only in a sandbox and compare close alternatives before using it for real work.
Stars
948 GitHub stars
Repo activity
948 stars, 94 forks
Maintenance
1mo since push
License
Apache-2.0
Install
npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performance
Install safety
Agent-readable metadata
Use this block or the embedded JSON to decide whether an agent should install this skill, choose an alternative, or ask for human review first.
Suited tasks
Suited agents
Install decision
Trust and risk
Outcome loop
Install command
npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performanceDo not use when
Alternative
174.2K Stars
npx skills add anthropics/skills --skill frontend-design
Alternative
84.4K Stars
npx skills add Leonxlnx/taste-skill --skill design-taste-frontend
Alternative
174.2K Stars
npx skills add anthropics/skills --skill canvas-design
Alternative
174.2K Stars
npx skills add anthropics/skills --skill brand-guidelines
Agent safety v2
Sparse or mixed signals. Useful for discovery, but not for autonomous installation.
Test manually in an isolated workspace and compare against safer alternatives.
high
Skill metadata references terminal, CLI, shell, subprocess, or command execution workflows.
medium
Skill likely fetches remote pages, APIs, repositories, or external services.
medium
Skill may read or write project files, documents, generated artifacts, or local workspace state.
Agent resolve plan
The Resolve API returns the selected skill, alternatives, safety policy, audit notes, install target, and copy-paste prompt an agent can follow without scraping this page.
Open JSON
/api/agent/resolve?task=Use%20gradle-build-performance%20for%20an%20agent%20workflow&agent=codex&max_risk=medium
Resolve text
/api/agent/resolve?task=Use%20gradle-build-performance%20for%20an%20agent%20workflow&agent=codex&max_risk=medium&format=text
Install handoff
/api/skills/new-silvermoon-gradle-build-performance/install
Agent should check
Copy prompt
Task: Use gradle-build-performance in this workspace.
Resolve first: https://www.openagentskill.com/api/agent/resolve?task=Use%20gradle-build-performance%20for%20an%20agent%20workflow&agent=codex&max_risk=medium
Review install handoff: https://www.openagentskill.com/api/skills/new-silvermoon-gradle-build-performance/install
Install command: npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performance
Before running it, summarize audit warnings, required permissions, and the fallback skill if install is risky.Agent handoff
Use the public install endpoint to fetch the command, safety checklist, target prompts, and canonical links for this skill.
Install handoff
/api/skills/new-silvermoon-gradle-build-performance/install
LLM text format
/api/skills/new-silvermoon-gradle-build-performance/install?format=text
Find alternatives
/api/skills/search?q=gradle-build-performance&limit=3
Agent prompt
Use gradle-build-performance for this task. Review https://www.openagentskill.com/api/skills/new-silvermoon-gradle-build-performance/install, then install with: npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performanceRegistry metadata
This page exposes the same decision, trust, audit, use-case, and install signals through the Registry API, so agents can rank this skill without scraping the UI.
Manifest
/api/registry/manifest/new-silvermoon-gradle-build-performance
LLM text
/api/registry/manifest/new-silvermoon-gradle-build-performance?format=text
Install alias
/api/registry/install/new-silvermoon-gradle-build-performance
Recommend
/api/registry/recommend?task=Use%20gradle-build-performance%20in%20an%20agent%20workflow&limit=3
Agent fit
Research agents
Use-case tags
Platforms
Claude Code
Audit report
A machine-readable review of install readiness, security metadata, maintenance, and adoption risk.
Agent decision cockpit
Shortlist this skill and compare it with close alternatives before production adoption.
Role in stack
Companion skill
Primary fit
Research agents
Trust label
Strong shortlist
Install path
Command ready
Use when
Evidence
review first
Implementation path
Trust profile
Useful candidate with missing or mixed trust signals. Keep it in an isolated workspace until the outcome loop proves task fit.
GitHub adoption
INFO948 GitHub stars
Stars/forks activity
INFO948 stars, 94 forks; issue activity unavailable in current metadata
Recent maintenance
PASS1mo since push
License clarity
PASSApache-2.0
Good signals
Review before install
Recommended action
Run only in a sandbox and compare close alternatives before using it for real work.
Quality profile
Solid option that is likely worth shortlisting for production workflows.
Workflow fit
Investigate faster
I need my agent to research a topic, compare sources, and produce a concise report.
Operate local tools
I need my agent to operate local files and desktop apps in a repeatable workflow.
Build and ship code
I need a coding agent that can understand a repository, edit code, and review pull requests.
Workflow fit
Turn skills into distribution
A workflow for turning newly indexed skills into SEO briefs, social drafts, comparison pages, and reusable publishing workflows.
Find, compare, and synthesize
A workflow for agents that gather sources, compare claims, summarize long material, and draft useful research briefs.
Inspect, patch, and verify code
A workflow for software agents that inspect repositories, review pull requests, generate tests, and turn findings into shippable patches.
Alternative shortlist
Similar skills that may fit this task.
Guidance for distinctive, intentional UI design, typography, visual direction, and non-template-like product interfaces.
Design and implementation guidance for distinctive landing pages, portfolios, product demos, and purposeful redesigns.
Create original visual art, posters, PNG assets, and PDF documents through a clear design philosophy.
Apply Anthropic official brand colors, typography, and visual standards to appropriate Anthropic-related artifacts.
--- name: gradle-build-performance description: Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating CI/CD performance, analyzing build scans, or identifying compilation bottlenecks. ---
# Gradle Build Performance
## When to Use
- Build times are slow (clean or incremental) - Investigating build performance regressions - Analyzing Gradle Build Scans - Identifying configuration vs execution bottlenecks - Optimizing CI/CD build times - Enabling Gradle Configuration Cache - Reducing unnecessary recompilation - Debugging kapt/KSP annotation processing
## Example Prompts
- "My builds are slow, how can I speed them up?" - "How do I analyze a Gradle build scan?" - "Why is configuration taking so long?" - "Why does my project always recompile everything?" - "How do I enable configuration cache?" - "Why is kapt so slow?"
---
## Workflow
1. **Measure Baseline** — Clean build + incremental build times 2. **Generate Build Scan** — `./gradlew assembleDebug --scan` 3. **Identify Phase** — Configuration? Execution? Dependency resolution? 4. **Apply ONE optimization** — Don't batch changes 5. **Measure Improvement** — Compare against baseline 6. **Verify in Build Scan** — Visual confirmation
---
## Quick Diagnostics
### Generate Build Scan
```bash ./gradlew assembleDebug --scan ```
### Profile Build Locally
```bash ./gradlew assembleDebug --profile # Opens report in build/reports/profile/ ```
### Build Timing Summary
```bash ./gradlew assembleDebug --info | grep -E "^\:.*" # Or view in Android Studio: Build > Analyze APK Build ```
---
## Build Phases
| Phase | What Happens | Common Issues | |-------|--------------|---------------| | **Initialization** | `settings.gradle.kts` evaluated | Too many `include()` statements | | **Configuration** | All `build.gradle.kts` files evaluated | Expensive plugins, eager task creation | | **Execution** | Tasks run based on inputs/outputs | Cache misses, non-incremental tasks |
### Identify the Bottleneck
``` Build scan → Performance → Build timeline ```
- **Long configuration phase**: Focus on plugin and buildscript optimization - **Long execution phase**: Focus on task caching and parallelization - **Dependency resolution slow**: Focus on repository configuration
---
## 12 Optimization Patterns
### 1. Enable Configuration Cache
Caches configuration phase across builds (AGP 8.0+):
```properties # gradle.properties org.gradle.configuration-cache=true org.gradle.configuration-cache.problems=warn ```
### 2. Enable Build Cache
Reuses task outputs across builds and machines:
```properties # gradle.properties org.gradle.caching=true ```
### 3. Enable Parallel Execution
Build independent modules simultaneously:
```properties # gradle.properties org.gradle.parallel=true ```
### 4. Increase JVM Heap
Allocate more memory for large projects:
```properties # gradle.properties org.gradle.jvmargs=-Xmx4g -XX:+UseParallelGC ```
### 5. Use Non-Transitive R Classes
Reduces R class size and compilation (AGP 8.0+ default):
```properties # gradle.properties android.nonTransitiveRClass=true ```
### 6. Migrate kapt to KSP
KSP is 2x faster than kapt for Kotlin:
```kotlin // Before (slow) kapt("com.google.dagger:hilt-compiler:2.51.1")
// After (fast) ksp("com.google.dagger:hilt-compiler:2.51.1") ```
### 7. Avoid Dynamic Dependencies
Pin dependency versions:
```kotlin // BAD: Forces resolution every build implementation("com.example:lib:+") implementation("com.example:lib:1.0.+")
// GOOD: Fixed version implementation("com.example:lib:1.2.3") ```
### 8. Optimize Repository Order
Put most-used repositories first:
```kotlin // settings.gradle.kts dependencyResolutionManagement { repositories { google() // First: Android dependencies mavenCentral() // Second: Most libraries // Third-party repos last } } ```
### 9. Use includeBuild for Local Modules
Composite builds are faster than `project()` for large monorepos:
```kotlin // settings.gradle.kts includeBuild("shared-library") { dependencySubstitution { substitute(module("com.example:shared")).using(project(":")) } } ```
### 10. Enable Incremental Annotation Processing
```properties # gradle.properties kapt.incremental.apt=true kapt.use.worker.api=true ```
### 11. Avoid Configuration-Time I/O
Don't read files or make network calls during configuration:
```kotlin // BAD: Runs during configuration val version = file("version.txt").readText()
// GOOD: Defer to execution val version = providers.fileContents(file("version.txt")).asText ```
### 12. Use Lazy Task Configuration
Avoid `create()`, use `register()`:
```kotlin // BAD: Eagerly configured tasks.create("myTask") { ... }
// GOOD: Lazily configured tasks.register("myTask") { ... } ```
---
## Common Bottleneck Analysis
### Slow Configuration Phase
**Symptoms**: Build scan shows long "Configuring build" time
**Causes & Fixes**: | Cause | Fix | |-------|-----| | Eager task creation | Use `tasks.register()` instead of `tasks.create()` | | buildSrc with many dependencies | Migrate to Convention Plugins with `includeBuild` | | File I/O in build scripts | Use `providers.fileContents()` | | Network calls in plugins | Cache results or use offline mode |
### Slow Compilation
**Symptoms**: `:app:compileDebugKotlin` takes too long
**Causes & Fixes**: | Cause | Fix | |-------|-----| | Non-incremental changes | Avoid `build.gradle.kts` changes that invalidate cache | | Large modules | Break into smaller feature modules | | Excessive kapt usage | Migrate to KSP | | Kotlin compiler memory | Increase `kotlin.daemon.jvmargs` |
### Cache Misses
**Symptoms**: Tasks always rerun despite no changes
**Causes & Fixes**: | Cause | Fix | |-------|-----| | Unstable task inputs | Use `@PathSensitive`, `@NormalizeLineEndings` | | Absolute paths in outputs | Use relative paths | | Missing `@CacheableTask` | Add annotation to custom tasks | | Different JDK versions | Standardize JDK across environments |
---
## CI/CD Optimizations
### Remote Build Cache
```kotlin // settings.gradle.kts buildCache { local { isEnabled = true } remote<HttpBuildCache> { url = uri("https://cache.example.com/") isPush = System.getenv("CI") == "true" credentials { username = System.getenv("CACHE_USER") password = System.getenv("CACHE_PASS") } } } ```
### Gradle Enterprise / Develocity
For advanced build analytics:
```kotlin // settings.gradle.kts plugins { id("com.gradle.develocity") version "3.17" }
develocity { buildScan { termsOfUseUrl.set("https://gradle.com/help/legal-terms-of-use") termsOfUseAgree.set("yes") publishing.onlyIf { System.getenv("CI") != null } } } ```
### Skip Unnecessary Tasks in CI
```bash # Skip tests for UI-only changes ./gradlew assembleDebug -x test -x lint
# Only run affected module tests ./gradlew :feature:login:test ```
---
## Android Studio Settings
### File → Settings → Build → Gradle
- **Gradle JDK**: Match your project's JDK - **Build and run using**: Gradle (not IntelliJ) - **Run tests using**: Gradle
### File → Settings → Build → Compiler
- **Compile independent modules in parallel**: ✅ Enabled - **Configure on demand**: ❌ Disabled (deprecated)
---
## Verification Checklist
After optimizations, verify:
- [ ] Configuration cache enabled and working - [ ] Build cache hit rate > 80% (check build scan) - [ ] No dynamic dependency versions - [ ] KSP used instead of kapt where possible - [ ] Parallel execution enabled - [ ] JVM memory tuned appropriately - [ ] CI remote cache configured - [ ] No configuration-time I/O
---
## References
- [Optimize Build Speed](https://developer.android.com/build/optimize-your-build) - [Gradle Configuration Cache](https://docs.gradle.org/current/userguide/configuration_cache.html) - [Gradle Build Cache](https://docs.gradle.org/current/userguide/build_cache.html) - [Migrate from kapt to KSP](https://developer.android.com/build/migrate-to-ksp) - [Gradle Build Scans](https://scans.gradle.com/)
Source provenance
Decision snapshot
948 GitHub stars
Audit
Install and adoption review
Agent-proven evidence
Outcome reports after resolve, review, install, and one narrow run.
No agent outcome data yet. The first agent run can report success, setup needs, risk blocks, failure, or not-relevant through /api/agent/outcome.
Install
Free and open source. Review the report before installing into production agents.
Growth loop
Scenario-led draft for gradle-build-performance, ready for a manual X post.
gradle-build-performance: Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating... 948 stars https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=x
Listing + install path for gradle-build-performance: https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=x Install: npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-p...
Listing source
This listing was indexed from public sources and is not marked official until a maintainer claim is approved.
Attribution links to the public repository or creator profile. Creators can claim the listing to update ownership signals.
Claim this skillOwner claim
This Registry indexed listing is attributed to new-silvermoon but is not marked official yet. Claim it to add a verified owner signal and make future launch, install, and audit updates easier to trust.
Creator backlink kit
Show the canonical listing, current trust and audit signals, and real Agent-Proven evidence where developers evaluate the repository.
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance/audit)
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)new-silvermoon
@new-silvermoon
Share whether this skill looks useful for your agent workflow. Aggregated feedback improves rankings over time.
Sandbox only
Frontend Design
Guidance for distinctive, intentional UI design, typography, visual direction, and non-template-like product interfaces.
174.2K StarsTaste Skill: Anti-Slop Frontend
Design and implementation guidance for distinctive landing pages, portfolios, product demos, and purposeful redesigns.
84.4K StarsCanvas Design
Create original visual art, posters, PNG assets, and PDF documents through a clear design philosophy.
174.2K StarsAnthropic Brand Guidelines
Apply Anthropic official brand colors, typography, and visual standards to appropriate Anthropic-related artifacts.
174.2K StarsSandbox only
Install targets
Codex install prompt
Install the "gradle-build-performance" agent skill from https://github.com/new-silvermoon/awesome-android-agent-skills/tree/main/.github/skills/performance/gradle-build-performance. Read its SKILL.md or equivalent instructions first, install only the files needed for this workspace, and summarize any required setup before using it. Skill purpose: Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating CI/CD performance, analyzing build scans, or identifying compilation bottlenecks. After the install attempt, report the result to https://www.openagentskill.com/api/agent/outcome with POST JSON {"event_id":"install_<unique-id>","skill_slug":"new-silvermoon-gradle-build-performance","task":"Install gradle-build-performance","agent":"codex","outcome":"success","install_used":true}. Replace event_id with a unique value and outcome with success or failed. Report success only after the skill is installed and a minimal verification passes.Supply asset profile
Code review, repo analysis, testing, CI, GitHub, DevOps, and developer workflow skills.
Scenario
Coding agents
I need a coding agent that can understand a repository, edit code, and review pull requests.
Agent fit
Claude Code + CLI + Codex
Codex, Claude Code, Cursor, CLI, or custom agents.
Install
Ready
npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performance
Maintenance
active
1mo since push
Risk
Needs review
Permission surface may require sandboxing
GitHub quality
948
70/100 Quality · 76/100 Trust
Coverage tags
Review notes
Permission surface may require sandboxing · Quality score needs review
Agent adoption scorecard
These scores combine public repository metadata, OpenAgentSkill review signals, maintenance freshness, and install readiness. They are a shortlist signal, not a replacement for human review.
Quality
StrongSolid option that is likely worth shortlisting for production workflows.
Trust
Sandbox onlyUseful candidate with missing or mixed trust signals. Keep it in an isolated workspace until the outcome loop proves task fit.
Audit
Needs reviewA machine-readable review of install readiness, security metadata, maintenance, and adoption risk.
OpenAgentSkill Trust Score v5
Run only in a sandbox and compare close alternatives before using it for real work.
Stars
948 GitHub stars
Repo activity
948 stars, 94 forks
Maintenance
1mo since push
License
Apache-2.0
Install
npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performance
Install safety
Agent-readable metadata
Use this block or the embedded JSON to decide whether an agent should install this skill, choose an alternative, or ask for human review first.
Suited tasks
Suited agents
Install decision
Trust and risk
Outcome loop
Install command
npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performanceDo not use when
Alternative
174.2K Stars
npx skills add anthropics/skills --skill frontend-design
Alternative
84.4K Stars
npx skills add Leonxlnx/taste-skill --skill design-taste-frontend
Alternative
174.2K Stars
npx skills add anthropics/skills --skill canvas-design
Alternative
174.2K Stars
npx skills add anthropics/skills --skill brand-guidelines
Agent safety v2
Sparse or mixed signals. Useful for discovery, but not for autonomous installation.
Test manually in an isolated workspace and compare against safer alternatives.
high
Skill metadata references terminal, CLI, shell, subprocess, or command execution workflows.
medium
Skill likely fetches remote pages, APIs, repositories, or external services.
medium
Skill may read or write project files, documents, generated artifacts, or local workspace state.
Agent resolve plan
The Resolve API returns the selected skill, alternatives, safety policy, audit notes, install target, and copy-paste prompt an agent can follow without scraping this page.
Open JSON
/api/agent/resolve?task=Use%20gradle-build-performance%20for%20an%20agent%20workflow&agent=codex&max_risk=medium
Resolve text
/api/agent/resolve?task=Use%20gradle-build-performance%20for%20an%20agent%20workflow&agent=codex&max_risk=medium&format=text
Install handoff
/api/skills/new-silvermoon-gradle-build-performance/install
Agent should check
Copy prompt
Task: Use gradle-build-performance in this workspace.
Resolve first: https://www.openagentskill.com/api/agent/resolve?task=Use%20gradle-build-performance%20for%20an%20agent%20workflow&agent=codex&max_risk=medium
Review install handoff: https://www.openagentskill.com/api/skills/new-silvermoon-gradle-build-performance/install
Install command: npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performance
Before running it, summarize audit warnings, required permissions, and the fallback skill if install is risky.Agent handoff
Use the public install endpoint to fetch the command, safety checklist, target prompts, and canonical links for this skill.
Install handoff
/api/skills/new-silvermoon-gradle-build-performance/install
LLM text format
/api/skills/new-silvermoon-gradle-build-performance/install?format=text
Find alternatives
/api/skills/search?q=gradle-build-performance&limit=3
Agent prompt
Use gradle-build-performance for this task. Review https://www.openagentskill.com/api/skills/new-silvermoon-gradle-build-performance/install, then install with: npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-performanceRegistry metadata
This page exposes the same decision, trust, audit, use-case, and install signals through the Registry API, so agents can rank this skill without scraping the UI.
Manifest
/api/registry/manifest/new-silvermoon-gradle-build-performance
LLM text
/api/registry/manifest/new-silvermoon-gradle-build-performance?format=text
Install alias
/api/registry/install/new-silvermoon-gradle-build-performance
Recommend
/api/registry/recommend?task=Use%20gradle-build-performance%20in%20an%20agent%20workflow&limit=3
Agent fit
Research agents
Use-case tags
Platforms
Claude Code
Audit report
A machine-readable review of install readiness, security metadata, maintenance, and adoption risk.
Agent decision cockpit
Shortlist this skill and compare it with close alternatives before production adoption.
Role in stack
Companion skill
Primary fit
Research agents
Trust label
Strong shortlist
Install path
Command ready
Use when
Evidence
review first
Implementation path
Trust profile
Useful candidate with missing or mixed trust signals. Keep it in an isolated workspace until the outcome loop proves task fit.
GitHub adoption
INFO948 GitHub stars
Stars/forks activity
INFO948 stars, 94 forks; issue activity unavailable in current metadata
Recent maintenance
PASS1mo since push
License clarity
PASSApache-2.0
Good signals
Review before install
Recommended action
Run only in a sandbox and compare close alternatives before using it for real work.
Quality profile
Solid option that is likely worth shortlisting for production workflows.
Workflow fit
Investigate faster
I need my agent to research a topic, compare sources, and produce a concise report.
Operate local tools
I need my agent to operate local files and desktop apps in a repeatable workflow.
Build and ship code
I need a coding agent that can understand a repository, edit code, and review pull requests.
Workflow fit
Turn skills into distribution
A workflow for turning newly indexed skills into SEO briefs, social drafts, comparison pages, and reusable publishing workflows.
Find, compare, and synthesize
A workflow for agents that gather sources, compare claims, summarize long material, and draft useful research briefs.
Inspect, patch, and verify code
A workflow for software agents that inspect repositories, review pull requests, generate tests, and turn findings into shippable patches.
Alternative shortlist
Similar skills that may fit this task.
Guidance for distinctive, intentional UI design, typography, visual direction, and non-template-like product interfaces.
Design and implementation guidance for distinctive landing pages, portfolios, product demos, and purposeful redesigns.
Create original visual art, posters, PNG assets, and PDF documents through a clear design philosophy.
Apply Anthropic official brand colors, typography, and visual standards to appropriate Anthropic-related artifacts.
--- name: gradle-build-performance description: Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating CI/CD performance, analyzing build scans, or identifying compilation bottlenecks. ---
# Gradle Build Performance
## When to Use
- Build times are slow (clean or incremental) - Investigating build performance regressions - Analyzing Gradle Build Scans - Identifying configuration vs execution bottlenecks - Optimizing CI/CD build times - Enabling Gradle Configuration Cache - Reducing unnecessary recompilation - Debugging kapt/KSP annotation processing
## Example Prompts
- "My builds are slow, how can I speed them up?" - "How do I analyze a Gradle build scan?" - "Why is configuration taking so long?" - "Why does my project always recompile everything?" - "How do I enable configuration cache?" - "Why is kapt so slow?"
---
## Workflow
1. **Measure Baseline** — Clean build + incremental build times 2. **Generate Build Scan** — `./gradlew assembleDebug --scan` 3. **Identify Phase** — Configuration? Execution? Dependency resolution? 4. **Apply ONE optimization** — Don't batch changes 5. **Measure Improvement** — Compare against baseline 6. **Verify in Build Scan** — Visual confirmation
---
## Quick Diagnostics
### Generate Build Scan
```bash ./gradlew assembleDebug --scan ```
### Profile Build Locally
```bash ./gradlew assembleDebug --profile # Opens report in build/reports/profile/ ```
### Build Timing Summary
```bash ./gradlew assembleDebug --info | grep -E "^\:.*" # Or view in Android Studio: Build > Analyze APK Build ```
---
## Build Phases
| Phase | What Happens | Common Issues | |-------|--------------|---------------| | **Initialization** | `settings.gradle.kts` evaluated | Too many `include()` statements | | **Configuration** | All `build.gradle.kts` files evaluated | Expensive plugins, eager task creation | | **Execution** | Tasks run based on inputs/outputs | Cache misses, non-incremental tasks |
### Identify the Bottleneck
``` Build scan → Performance → Build timeline ```
- **Long configuration phase**: Focus on plugin and buildscript optimization - **Long execution phase**: Focus on task caching and parallelization - **Dependency resolution slow**: Focus on repository configuration
---
## 12 Optimization Patterns
### 1. Enable Configuration Cache
Caches configuration phase across builds (AGP 8.0+):
```properties # gradle.properties org.gradle.configuration-cache=true org.gradle.configuration-cache.problems=warn ```
### 2. Enable Build Cache
Reuses task outputs across builds and machines:
```properties # gradle.properties org.gradle.caching=true ```
### 3. Enable Parallel Execution
Build independent modules simultaneously:
```properties # gradle.properties org.gradle.parallel=true ```
### 4. Increase JVM Heap
Allocate more memory for large projects:
```properties # gradle.properties org.gradle.jvmargs=-Xmx4g -XX:+UseParallelGC ```
### 5. Use Non-Transitive R Classes
Reduces R class size and compilation (AGP 8.0+ default):
```properties # gradle.properties android.nonTransitiveRClass=true ```
### 6. Migrate kapt to KSP
KSP is 2x faster than kapt for Kotlin:
```kotlin // Before (slow) kapt("com.google.dagger:hilt-compiler:2.51.1")
// After (fast) ksp("com.google.dagger:hilt-compiler:2.51.1") ```
### 7. Avoid Dynamic Dependencies
Pin dependency versions:
```kotlin // BAD: Forces resolution every build implementation("com.example:lib:+") implementation("com.example:lib:1.0.+")
// GOOD: Fixed version implementation("com.example:lib:1.2.3") ```
### 8. Optimize Repository Order
Put most-used repositories first:
```kotlin // settings.gradle.kts dependencyResolutionManagement { repositories { google() // First: Android dependencies mavenCentral() // Second: Most libraries // Third-party repos last } } ```
### 9. Use includeBuild for Local Modules
Composite builds are faster than `project()` for large monorepos:
```kotlin // settings.gradle.kts includeBuild("shared-library") { dependencySubstitution { substitute(module("com.example:shared")).using(project(":")) } } ```
### 10. Enable Incremental Annotation Processing
```properties # gradle.properties kapt.incremental.apt=true kapt.use.worker.api=true ```
### 11. Avoid Configuration-Time I/O
Don't read files or make network calls during configuration:
```kotlin // BAD: Runs during configuration val version = file("version.txt").readText()
// GOOD: Defer to execution val version = providers.fileContents(file("version.txt")).asText ```
### 12. Use Lazy Task Configuration
Avoid `create()`, use `register()`:
```kotlin // BAD: Eagerly configured tasks.create("myTask") { ... }
// GOOD: Lazily configured tasks.register("myTask") { ... } ```
---
## Common Bottleneck Analysis
### Slow Configuration Phase
**Symptoms**: Build scan shows long "Configuring build" time
**Causes & Fixes**: | Cause | Fix | |-------|-----| | Eager task creation | Use `tasks.register()` instead of `tasks.create()` | | buildSrc with many dependencies | Migrate to Convention Plugins with `includeBuild` | | File I/O in build scripts | Use `providers.fileContents()` | | Network calls in plugins | Cache results or use offline mode |
### Slow Compilation
**Symptoms**: `:app:compileDebugKotlin` takes too long
**Causes & Fixes**: | Cause | Fix | |-------|-----| | Non-incremental changes | Avoid `build.gradle.kts` changes that invalidate cache | | Large modules | Break into smaller feature modules | | Excessive kapt usage | Migrate to KSP | | Kotlin compiler memory | Increase `kotlin.daemon.jvmargs` |
### Cache Misses
**Symptoms**: Tasks always rerun despite no changes
**Causes & Fixes**: | Cause | Fix | |-------|-----| | Unstable task inputs | Use `@PathSensitive`, `@NormalizeLineEndings` | | Absolute paths in outputs | Use relative paths | | Missing `@CacheableTask` | Add annotation to custom tasks | | Different JDK versions | Standardize JDK across environments |
---
## CI/CD Optimizations
### Remote Build Cache
```kotlin // settings.gradle.kts buildCache { local { isEnabled = true } remote<HttpBuildCache> { url = uri("https://cache.example.com/") isPush = System.getenv("CI") == "true" credentials { username = System.getenv("CACHE_USER") password = System.getenv("CACHE_PASS") } } } ```
### Gradle Enterprise / Develocity
For advanced build analytics:
```kotlin // settings.gradle.kts plugins { id("com.gradle.develocity") version "3.17" }
develocity { buildScan { termsOfUseUrl.set("https://gradle.com/help/legal-terms-of-use") termsOfUseAgree.set("yes") publishing.onlyIf { System.getenv("CI") != null } } } ```
### Skip Unnecessary Tasks in CI
```bash # Skip tests for UI-only changes ./gradlew assembleDebug -x test -x lint
# Only run affected module tests ./gradlew :feature:login:test ```
---
## Android Studio Settings
### File → Settings → Build → Gradle
- **Gradle JDK**: Match your project's JDK - **Build and run using**: Gradle (not IntelliJ) - **Run tests using**: Gradle
### File → Settings → Build → Compiler
- **Compile independent modules in parallel**: ✅ Enabled - **Configure on demand**: ❌ Disabled (deprecated)
---
## Verification Checklist
After optimizations, verify:
- [ ] Configuration cache enabled and working - [ ] Build cache hit rate > 80% (check build scan) - [ ] No dynamic dependency versions - [ ] KSP used instead of kapt where possible - [ ] Parallel execution enabled - [ ] JVM memory tuned appropriately - [ ] CI remote cache configured - [ ] No configuration-time I/O
---
## References
- [Optimize Build Speed](https://developer.android.com/build/optimize-your-build) - [Gradle Configuration Cache](https://docs.gradle.org/current/userguide/configuration_cache.html) - [Gradle Build Cache](https://docs.gradle.org/current/userguide/build_cache.html) - [Migrate from kapt to KSP](https://developer.android.com/build/migrate-to-ksp) - [Gradle Build Scans](https://scans.gradle.com/)
Source provenance
Decision snapshot
948 GitHub stars
Audit
Install and adoption review
Agent-proven evidence
Outcome reports after resolve, review, install, and one narrow run.
No agent outcome data yet. The first agent run can report success, setup needs, risk blocks, failure, or not-relevant through /api/agent/outcome.
Install
Free and open source. Review the report before installing into production agents.
Growth loop
Scenario-led draft for gradle-build-performance, ready for a manual X post.
gradle-build-performance: Debug and optimize Android/Gradle build performance. Use when builds are slow, investigating... 948 stars https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=x
Listing + install path for gradle-build-performance: https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=x Install: npx skills add new-silvermoon/awesome-android-agent-skills --skill gradle-build-p...
Listing source
This listing was indexed from public sources and is not marked official until a maintainer claim is approved.
Attribution links to the public repository or creator profile. Creators can claim the listing to update ownership signals.
Claim this skillOwner claim
This Registry indexed listing is attributed to new-silvermoon but is not marked official yet. Claim it to add a verified owner signal and make future launch, install, and audit updates easier to trust.
Creator backlink kit
Show the canonical listing, current trust and audit signals, and real Agent-Proven evidence where developers evaluate the repository.
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance/audit)
[](https://www.openagentskill.com/skills/new-silvermoon-gradle-build-performance?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)new-silvermoon
@new-silvermoon
Share whether this skill looks useful for your agent workflow. Aggregated feedback improves rankings over time.
Sandbox only
Frontend Design
Guidance for distinctive, intentional UI design, typography, visual direction, and non-template-like product interfaces.
174.2K StarsTaste Skill: Anti-Slop Frontend
Design and implementation guidance for distinctive landing pages, portfolios, product demos, and purposeful redesigns.
84.4K StarsCanvas Design
Create original visual art, posters, PNG assets, and PDF documents through a clear design philosophy.
174.2K StarsAnthropic Brand Guidelines
Apply Anthropic official brand colors, typography, and visual standards to appropriate Anthropic-related artifacts.
174.2K StarsPermission surface
secrets or environment access, shell or command execution
Agent outcomes
No agent outcome data yet
Docs
Strong README/SKILL.md context
Risk summary
Install readiness
Permission surface
secrets or environment access, shell or command execution
Agent outcomes
No agent outcome data yet
Docs
Strong README/SKILL.md context
Risk summary
Install readiness
Permission surface
secrets or environment access, shell or command execution
Agent outcomes
No agent outcome data yet
Docs
Strong README/SKILL.md context
Risk summary
Install readiness
Permission surface
secrets or environment access, shell or command execution
Agent outcomes
No agent outcome data yet
Docs
Strong README/SKILL.md context
Risk summary
Install readiness