Problem
cargo install outputs verbose compilation logs (dependency resolution, compiling N crates, warnings) when only the final "Installing/Installed/Replacing" lines matter for LLM context.
Evidence
rtk discover on 405 sessions (30 days) shows 53 occurrences of cargo install as the #2 unhandled command by count.
Command Count Example
cargo install 53 cargo install --path . --force
Typical output is 50-200 lines of compilation noise for 2-3 useful lines.
Proposed behavior
rtk cargo install [args] should:
- Execute
cargo install [args] normally
- Filter output to show only:
Installing / Installed / Replacing / Compiling rtk v... (the target crate only)
- Errors and warnings from the target crate
- Final status line
- Strip all intermediate
Compiling dependency_name v... lines
- Preserve exit code
Example
Before (raw):
Installing rtk v0.11.0
Updating crates.io index
Locking 130 packages to latest compatible versions
Adding colored v2.2.0 (available: v3.1.1)
Adding dirs v5.0.1 (available: v6.0.0)
... (50+ lines)
Compiling proc-macro2 v1.0.70
Compiling unicode-ident v1.0.12
... (100+ lines)
Compiling rtk v0.11.0
Finished release profile
Replacing /Users/user/.cargo/bin/rtk
Replaced package `rtk v0.9.4` with `rtk v0.11.0` (executable `rtk`)
After (rtk filtered):
Installing rtk v0.11.0 (130 deps)
Compiling rtk v0.11.0
Replaced rtk v0.9.4 -> v0.11.0
Estimated savings: 80-90% token reduction.
Notes
This could be handled as a subcommand of the existing rtk cargo module, extending the match in cargo_cmd.rs (or equivalent) to intercept install alongside build, test, clippy, check.
Problem
cargo installoutputs verbose compilation logs (dependency resolution, compiling N crates, warnings) when only the final "Installing/Installed/Replacing" lines matter for LLM context.Evidence
rtk discoveron 405 sessions (30 days) shows 53 occurrences ofcargo installas the #2 unhandled command by count.Typical output is 50-200 lines of compilation noise for 2-3 useful lines.
Proposed behavior
rtk cargo install [args]should:cargo install [args]normallyInstalling/Installed/Replacing/Compiling rtk v...(the target crate only)Compiling dependency_name v...linesExample
Before (raw):
After (rtk filtered):
Estimated savings: 80-90% token reduction.
Notes
This could be handled as a subcommand of the existing
rtk cargomodule, extending the match incargo_cmd.rs(or equivalent) to interceptinstallalongsidebuild,test,clippy,check.