Deletion progress spinner + agent-var classification fix (§4) - #2
Merged
Conversation
Progress feedback: - `vacuum clean --apply` now shows a live steady-tick spinner with `[i/N]` and the current path during deletion, so a long removal (e.g. a multi-GB `target/`) no longer looks frozen after the user confirms. Each candidate is a single blocking removal, so a spinner — not a percent bar — is the honest signal. Implemented with `indicatif`, contained to `vacuum-cli` (`execute_candidates` in app.rs); `vacuum-core` stays UI-free. - Renders only in human/TTY mode, never for `--quiet`, dry-runs, or JSON/JSONL/agent output; drawn to stderr so stdout stays data-only (SFRS §7). Uncolored template satisfies NO_COLOR. Agent detection (agentic-cli §4 conformance): - Split agent env vars into forcing (AI_AGENT, AGENT, CI) vs informational (CLAUDECODE, CURSOR_AGENT, GEMINI_CLI). Only forcing vars change output mode / suppress the TUI; the informational ones previously (incorrectly) forced JSON. - Informational agents now surface in `metadata.invoking_agent` (telemetry only, omitted when absent). This matches what the manual already documented. - Extracted the pure `first_set` classifier and added unit tests for it. Gate: cargo fmt / clippy -D warnings / test --workspace (16 tests) / reuse lint all pass. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two related UX/conformance improvements to
vacuum clean, surfaced while testing the freshly-installed CLI.1. Deletion progress spinner
Previously, after confirming a real deletion (
y, or--apply --yes),run_cleandeleted in a loop and printed nothing until the whole loop finished — a multi-GBtarget/made the terminal look frozen.Now
vacuum clean --applyshows a live spinner:--quiet, dry-runs, and JSON/JSONL/agent output; uncolored template satisfiesNO_COLOR.indicatif, contained tovacuum-cli(execute_candidatesinapp.rs);vacuum-corestays UI-free.2. Agent-var classification fix (agentic-cli §4)
Testing showed the spinner never appeared under Claude Code because
CLAUDECODEwas treated as a JSON-forcing agent var. Per agentic-cli §4,CLAUDECODE/CURSOR_AGENT/GEMINI_CLIare informational only.AI_AGENT,AGENT,CI(change output mode / suppress TUI); informational =CLAUDECODE,CURSOR_AGENT,GEMINI_CLI(no behavioral effect).metadata.invoking_agent(telemetry only, omitted when absent) — which is what the manual already documented.first_setclassifier and added unit tests.Verification
invoking_agent:"CLAUDECODE"appears in the envelope whileAI_AGENTstill correctly forces JSON.cargo fmt·clippy -D warnings·cargo test --workspace(16 tests) ·reuse lint. Commit signed/verified (§6.3).🤖 Generated with Claude Code