Skip to content

feat: add Maven command filter - #523

Closed
rmarioo wants to merge 1 commit into
rtk-ai:developfrom
rmarioo:feat/maven-filter
Closed

rmarioo wants to merge 1 commit into
rtk-ai:developfrom
rmarioo:feat/maven-filter

Conversation

@rmarioo

@rmarioo rmarioo commented Mar 11, 2026

Copy link
Copy Markdown

Summary

  • Add rtk mvn command filter for Maven build and test output
  • Achieves 60-90% token savings by extracting only errors, failures, and summaries
  • Supports mvn compile, mvn test, mvn package, mvn install, mvn clean, and other Maven goals
  • Adds Maven to discover rules for automatic detection

Changes

  • src/mvn_cmd.rs (new): Maven command filter with build error extraction, test failure parsing, and summary condensing
  • src/main.rs: Register Mvn command variant and routing
  • src/discover/rules.rs: Add Maven discovery rule
  • README.md: Document Maven support and token savings
  • tests/fixtures/: Real Maven build and test output fixtures

Test plan

  • 14 unit tests covering build success/failure, test success/failure, edge cases
  • Token savings verified ≥60% on real Maven output
  • cargo fmt --check passes
  • cargo clippy — 0 errors (warnings are pre-existing)
  • All 777 existing tests still pass (1 pre-existing failure unrelated to this PR)

🤖 Generated with Claude Code

@CLAassistant

CLAassistant commented Mar 20, 2026 •

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

@pszymkowiak

Copy link
Copy Markdown
Collaborator

Hi! Two things needed before we can review:

  1. Retarget to develop — this PR targets master, but all PRs should target develop. You can change the base branch in the PR settings (right sidebar).
  2. Sign the CLA — if not already done, please sign at https://cla-assistant.io/rtk-ai/rtk

Thanks!

@aeppling

Copy link
Copy Markdown
Contributor

Hey

We are cleaning up the codebase and improving the project structure for better onboarding. As part of this effort, PR #826 reorganizes src/ from a flat layout into subfolders.

No logic changes — only file moves and import path updates.

What you need to do

Rebase your branch on develop when receiving this comment:

git fetch origin && git rebase origin/develop

Git detects renames automatically. If you get import conflicts, update the paths:

use crate::git;        // now: use crate::cmds::git::git;
use crate::tracking;   // now: use crate::core::tracking;
use crate::config;     // now: use crate::core::config;
use crate::init;       // now: use crate::hooks::init;
use crate::gain;       // now: use crate::analytics::gain;

Need help rebasing? Tag @aeppling

@rmarioo
rmarioo changed the base branch from master to develop March 27, 2026 21:34
@rmarioo
rmarioo force-pushed the feat/maven-filter branch from f919902 to 6abb141 Compare March 27, 2026 21:43
@rmarioo
rmarioo force-pushed the feat/maven-filter branch from 6abb141 to 7494f24 Compare April 9, 2026 17:16
@matheus-meneses

Copy link
Copy Markdown
Contributor

Any updates, guys?

@rmarioo
rmarioo force-pushed the feat/maven-filter branch from 7494f24 to 294e33b Compare May 9, 2026 13:20
@rmarioo

rmarioo commented May 9, 2026

Copy link
Copy Markdown
Author

Hi @pszymkowiak @aeppling — quick update:

  • ✅ Rebased on develop (force-pushed): conflicts in src/main.rs, src/cmds/jvm/mod.rs and README.md resolved. Maven filter now lives at src/cmds/jvm/mvn_cmd.rs alongside gradlew_cmd.rs, picked up via automod::dir!.
  • ✅ CLA signed (mariorusso831).
  • ✅ Quality gate green: cargo fmt --check, cargo clippy --all-targets (0 errors), cargo test --all (1830 passed).
  • ✅ GitHub now reports the PR as MERGEABLE.

Ready for review whenever you have a moment — thanks!

@rtk-release-bot

Copy link
Copy Markdown
Contributor

This pull request has been automatically marked as stale due to 90 days of inactivity. If this pull request is still relevant, please leave any comment (for example, "bump"), and we'll keep it open. Your contribution is very much appreciated — we're sorry we haven't been able to review it yet.

@rtk-release-bot rtk-release-bot Bot added the stale label Sep 3, 2026
@KuSh

KuSh commented Sep 6, 2026

Copy link
Copy Markdown
Collaborator

Thanks for this. Maven support landed on develop in #1956 (merged 2026-09-05), which added src/cmds/jvm/mvn_cmd.rs along with the rtk mvn routing and the Maven discover rule that this PR introduced, and #3199 later added rtk mvnd on top. The build and test fixtures here are covered by a broader set already in tests/fixtures, including reactor, locale and no-pom cases. Closing as covered; if some part of the filtering here is still missing from the current implementation, please comment and it can be reopened.

@KuSh KuSh closed this Sep 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants