feat(gradlew): Gradle support for Android/Kotlin developers#312
feat(gradlew): Gradle support for Android/Kotlin developers#312kherembourg wants to merge 2 commits intortk-ai:masterfrom
Conversation
655e291 to
d407be4
Compare
|
Hi @yonatankarp, @rubixhacker, @kherembourg! Three Gradle PRs are open at the same time (#263, #288, #312) — they overlap significantly on |
|
Strong implementation — best architecture of the Gradle PRs (streaming/batch/passthrough). 48 tests, real fixtures, Windows
Note: 3 other PRs cover similar scope (#288, #368, #374). This is the strongest Gradle implementation so far. |
|
Note: this PR adds rules to Please remove the changes to |
|
I am very much fine with picking either, I implemented very basic functionality just so the PR will not endup as 24k lines of code 😄 |
|
Hello @yonatankarp We can also merge everything with your PR @rubixhacker but I personally prefer to not mix maven and gradle. |
d407be4 to
d34813e
Compare
|
Thanks for the thorough review @pszymkowiak! All 5 items addressed in the latest push (rebased on master + 1 fix commit):
772 tests passing (61 gradlew + 163 discover + rest of suite), |
|
Done ✅ — removed all changes to Added gradle patterns to Rust instead:
|
|
I am good with dropping my PR @kherembourg and doing a separate one targeting Maven 😄 Your PR is more comprehensive for Gradle |
|
Thanks @rubixhacker |
|
Any update on when this will be merged? |
|
Reviewing the code, I think I prefer this PR instead of #381 Sorry @sebastianbarrozo 😄 |
… indicator Comprehensive Gradle/Android support: build, test, lint, clean, install, uninstall, check, and dependencies filters with live progress spinner. Falls back to system gradle when wrapper not found. Hook rewrites ./gradlew and gradle commands automatically. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…ot tests - Move gradle hook rewrites from bash to Rust (rules.rs/registry.rs) - Remove gradle section from rtk-suggest.sh (now handled by rtk rewrite) - Route `check` task to Test filter (was Build, dropped test failures) - Strip INSTRUMENTATION_CODE: lines in connected test filter - Raise token savings thresholds from 40% to 60% (project minimum) - Add 6 insta::assert_snapshot! tests for all filter outputs - Add 9 registry tests for gradle rewrite patterns - Expand lint fixture for realistic savings (>60%) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
d34813e to
a5f7d4a
Compare
|
I understand reviewers are likely swamped with PRs right now, so it might take a while to get a full review. Happy to make any changes needed to help move this along, just let me know! |
Summary
Comprehensive Gradle support for Android and Kotlin developers using
./gradlew(orgradle). Filters verbose Gradle output down to what matters — status, errors, and results — with 60–85% token savings depending on the task.This PR covers the full Android development workflow: building, testing, linting, installing to devices, dependency inspection, and project cleanup.
Commands Handled
rtk gradlew assembleDebugrtk gradlew bundleReleasertk gradlew cleanrtk gradlew installDebugrtk gradlew uninstallDebugrtk gradlew checkrtk gradlew testDebugUnitTestrtk gradlew connectedDebugAndroidTestrtk gradlew lintrtk gradlew dependenciesrtk gradlew <other>Features
is_terminal()guard)gradlewhen./gradlewwrapper is not found in the project--stacktrace,--info,--debugflags bypass all filtering for full outputrtk ./gradlewandrtk gradleboth work as aliases forrtk gradlew./gradlew <cmd>andgradle <cmd>are automatically rewritten tortk gradlew <cmd>by the hookgradlew.batdetected automaticallyArchitecture
cleanargument determines the filter strategy> Task :progress lines, daemon messages, configuration noise; keeps BUILD SUCCESSFUL/FAILED, error lines, and warningsQuality Checks
cargo fmt --all --check— cleancargo clippy --all-targets— no new warningscargo test --all— 494 passed, 0 failed./gradlewoutput on an Android projectgradlerewrite supportManual Testing
Manually tested on a real Android project with
./gradlew:rtk gradlew assembleDebug— build filtered correctly, progress spinner visible in terminalrtk gradlew testDebugUnitTest— only test results shownrtk gradlew clean— task noise stripped, BUILD result preservedrtk gradlew check— mixed test+lint output filtered correctlyrtk gradlew installDebug— install filtered like buildrtk gradlew dependencies— only top-level deps shown per configurationrtk ./gradlew testDebugUnitTest— alias works--stacktrace)rtk gradlew assembleDebug | cat)🤖 Generated with Claude Code