GitHub

Go CLI for Gradle

Cut the noise from
every Gradle build.

build-brief wraps gradle / ./gradlew, keeps the full raw log on disk, and replaces walls of task output with a concise summary -- so you and your AI agents instantly see what succeeded, what failed, and which warnings are worth your attention.

terminal -- build-brief :androidApp:clean :androidApp:assembleDebug
$ build-brief :androidApp:clean :androidApp:assembleDebug BUILD SUCCESSFUL in 1s Artifacts: - APK: androidApp/build/outputs/apk/debug/androidApp-debug.apk (24.5 MB) Compilation outputs omitted: - 1 generated source/codegen file updated.

414 lines of raw Gradle output → 5 lines printed.


How it works

Drop-in. Zero config.

Prefix your Gradle command. build-brief handles the rest.

01

Prefix the command

Replace ./gradlew build with build-brief build. All Gradle flags pass through via --, e.g. build-brief -- --stacktrace test.

02

Full log hits disk

Every line Gradle emits is written to a log file like build-brief-6c5b629d.latest.log. Control where with --log-dir. Nothing is lost.

03

Terminal gets the brief

Success stays concise: build status, warnings, and when build-brief can reliably extract them, key outputs like artifact paths. Failure surfaces structured diagnostics: failed tasks, compiler errors, and the raw log path. The Gradle exit code is always preserved.


Before & After

Same build. Less noise.

A real 16-module Android/KMP project (:androidApp:assembleDebug). Left: raw Gradle output from a clean assembleDebug run (414 lines). Right: exactly what build-brief printed for that same command.

Before · Raw Gradle log 414 lines
Configuration on demand is an incubating feature. Reusing configuration cache. > Task :domain:androidPreBuild UP-TO-DATE > Task :core:androidPreBuild UP-TO-DATE > Task :designsystem:androidPreBuild UP-TO-DATE > Task :feature-events:androidPreBuild UP-TO-DATE > Task :feature-rankings:androidPreBuild UP-TO-DATE > Task :androidApp:preBuild UP-TO-DATE > Task :feature-events:preAndroidMainBuild UP-TO-DATE > Task :feature-matches:androidPreBuild UP-TO-DATE > Task :feature-player:androidPreBuild UP-TO-DATE > Task :androidApp:preDebugBuild UP-TO-DATE > Task :data:androidPreBuild UP-TO-DATE > Task :feature-about:androidPreBuild UP-TO-DATE > Task :core:preAndroidMainBuild UP-TO-DATE > Task :domain:preAndroidMainBuild UP-TO-DATE > Task :data:preAndroidMainBuild UP-TO-DATE > Task :designsystem:preAndroidMainBuild UP-TO-DATE > Task :feature-events:generateAndroidMainEmptyResourceFiles UP-TO-DATE > Task :feature-about:preAndroidMainBuild UP-TO-DATE > Task :feature-matches:preAndroidMainBuild UP-TO-DATE > Task :feature-news:androidPreBuild UP-TO-DATE > Task :feature-player:preAndroidMainBuild UP-TO-DATE > Task :feature-rankings:preAndroidMainBuild UP-TO-DATE ... 390+ additional lines omitted for layout ... > Task :androidApp:mergeProjectDexDebug FROM-CACHE > Task :androidApp:mergeExtDexDebug FROM-CACHE > Task :androidApp:mergeDebugJavaResource > Task :androidApp:packageDebug > Task :androidApp:assembleDebug > Task :androidApp:createDebugApkListingFileRedirect BUILD SUCCESSFUL in 1s 267 actionable tasks: 30 executed, 23 from cache, 214 up-to-date Configuration cache entry reused.
After · build-brief summary 5 lines
BUILD SUCCESSFUL in 1s Artifacts: - APK: androidApp/build/outputs/apk/debug/androidApp-debug.apk (24.5 MB) Compilation outputs omitted: - 1 generated source/codegen file updated.

▸ These logs were generated from a real source code project using build-brief against staticvar/vlr-gg. The public repo is the outward-facing project; the multi-module rewrite used for these logs is newer internal development — not fake or mocked. The after panel shows the exact 5 lines printed by a freshly built local copy of the current source. The raw panel is trimmed for layout; the full log contained 414 lines across androidApp, core, data, domain, designsystem, shared, and 10 feature modules.


When builds fail

Failures get the detail they need.

On success, build-brief prints one line. On failure, it extracts the failed tasks, compiler errors, and actionable diagnostics.

terminal -- build-brief build (failure)
$ build-brief build BUILD FAILED in 8s Command: gradlew --console=plain build Failed tasks: - :app:compileKotlin Highlights: - e: file:///.../Application.kt:15:25 Unresolved reference: serviceLocator - e: file:///.../Application.kt:22:9 Type mismatch: inferred type is String but Int was expected - > Task :app:compileKotlin FAILED - FAILURE: Build failed with an exception. - * What went wrong: - Execution failed for task ':app:compileKotlin'. - > Compilation error. See log for more details - * Try: - > Run with --stacktrace option to get the stack trace. - > Run with --info or --debug option to get more log output. Raw log: /tmp/build-brief/build-brief-33526f6a.latest.log

Exit code preserved. 29 raw lines reduced to 16.


What build-brief keeps

Only the lines that matter.

!

Failures & errors

Compilation errors, exception stack traces, and FAILED task markers surface immediately so you know exactly what broke.

w

Warnings

Kotlin and Java compiler warnings, deprecation notices, and linter diagnostics stay visible without the surrounding noise.

T

Test results

Test summaries and individual failure details are preserved. Passing tests stay quiet unless they fail.

>

Generated artifacts

JAR, AAR, APK, and bootJar output paths are shown so you know where your build products landed.

#

Build status

The final BUILD SUCCESSFUL / FAILED line, task counts, and timing are always printed. The Gradle exit code is preserved.

&

Full raw log

Every line goes to a timestamped file in /tmp. Nothing is ever discarded; you can always inspect the complete output.


Install

Up and running in seconds.

Pick your preferred method. No runtime dependencies beyond the binary.

install via curl
# Install or update build-brief curl -fsSL https://raw.githubusercontent.com/static-var/build-brief/main/install.sh | bash # Or with wget wget -qO- https://raw.githubusercontent.com/static-var/build-brief/main/install.sh | bash
install via Homebrew
brew tap static-var/tap brew install static-var/tap/build-brief
build from source
git clone https://github.com/static-var/build-brief.git cd build-brief go build -o build-brief ./cmd/build-brief mv build-brief /usr/local/bin/

Agent integration

Teach your AI tools to use it.

Every line of Gradle output an AI agent reads costs context-window tokens. A single assembleDebug can burn thousands of tokens on task lifecycle noise that tells the agent nothing useful. build-brief can install custom instructions so agents automatically route Gradle commands through it — reclaiming that context budget for reasoning about your code.

⚡ 414 lines → 5 lines. That's thousands of tokens back in your agent's context window.

AI coding agents (Copilot, Claude Code, Codex, Gemini) have finite context windows. Every token spent reading > Task :core:mergeDebugShaders NO-SOURCE is a token not spent understanding your code. build-brief keeps Gradle signal, discards lifecycle noise, and gives your agent more room to think.

GitHub Copilot CLI

Copilot plugin + instruction integration

Claude Code

Claude plugin + instruction integration

Codex CLI

Codex plugin + instruction integration

Gemini CLI

GEMINI.md instruction file

OpenCode

Custom instruction support

terminal -- build-brief rewrite
# Rewrite transforms Gradle commands for agent hooks $ build-brief rewrite 'gradle build' build-brief gradle build $ build-brief rewrite './gradlew test' build-brief ./gradlew test $ build-brief rewrite './gradlew --stacktrace assembleDebug' build-brief ./gradlew --stacktrace assembleDebug $ build-brief rewrite 'gradle test && gradle check' build-brief gradle test && build-brief gradle check
terminal -- instruction install
# Install instructions locally (updates AGENTS.md) $ build-brief --install # Install globally for detected AI tools $ build-brief --global

Measurement

Know what you're saving.

build-brief gains tracks cumulative token savings across every build. For AI agents, these savings translate directly to context-window budget reclaimed — capacity the agent can spend reasoning about your code instead of parsing Gradle task lifecycle output.

Token output comparison (real data from 38 tracked commands)

raw
80.9K
emitted
3.8K

95.4% reduction — 77.2K tokens saved across 38 commands

terminal -- build-brief gains
$ build-brief gains build-brief Token Savings (Global Scope) ============================================================ Total commands: 38 Raw tokens: 80.9K Emitted tokens: 3.8K Tokens saved: 77.2K (95.4%) Efficiency: |||||||||||||||||||||||| 95.4% By Command -------------------------------------------------------------- # Command Count Saved Avg% -------------------------------------------------------------- 1 gradlew :androidApp:assembl… 6 38.6K 98.2% 2 gradlew :androidApp:clean :… 6 32.7K 92.5% 3 gradlew build 9 2.6K 60.8% 4 gradlew assembleDebug 2 1.4K 99.1% 5 gradle clean jvmTest 6 848 47.5%

Ecosystem

Works wherever Gradle runs.

build-brief is build-script agnostic. If it runs through gradle or ./gradlew, it works.

Spring Boot Ktor Android Kotlin Multiplatform Plain JVM Multi-project builds Gradle Kotlin DSL Gradle Groovy DSL

Limitations

What it doesn't do.

~

build-brief is Gradle-only. It does not wrap Maven, Bazel, sbt, or other build tools.

~

Daemon mode defaults to auto. Use --daemon-mode on or --daemon-mode off to control it explicitly.

~

Inspired by RTK, but built separately because RTK is not compatible enough with Gradle workflows.

~

Output modes are human (default, filtered) and raw (pass-through). There is no intermediate verbosity level.


FAQ

Common questions.

Does build-brief change the Gradle exit code?

No. The Gradle exit code is preserved exactly. If Gradle exits with 1, build-brief exits with 1. CI pipelines, scripts, and && chains work as expected.

Where does the full log go?

To a log file whose path is printed on failure, such as /tmp/build-brief/build-brief-6c5b629d.latest.log. You can override the directory with --log-dir or the BUILD_BRIEF_LOG_DIR environment variable. Nothing is ever discarded.

Can I use it with ./gradlew and plain gradle?

Yes. build-brief build auto-detects the wrapper. You can also pass an explicit path: build-brief --gradle ./gradlew build or build-brief --gradle gradle build.

What about the Gradle daemon?

By default, build-brief uses --daemon-mode auto. You can control this with --daemon-mode on or --daemon-mode off. When using daemon mode on, consider --gradle-user-home for shared caches.

What does "token savings" mean?

AI coding agents have finite context windows — typically 100K–200K tokens. Every line of Gradle output they read consumes tokens from that budget. A single assembleDebug on a real 16-module project produces 414 lines of raw output; build-brief reduces that to 5. Across a working session, this reclaims tens of thousands of tokens the agent can use for reasoning about your code. build-brief gains tracks this cumulatively so you can see the concrete difference.

How is this different from RTK?

build-brief is inspired by RTK but built separately because RTK is not compatible enough with Gradle workflows. build-brief is purpose-built for Gradle's output patterns, task lifecycle, and error reporting.