Conversation
PR SummaryMedium Risk Overview Changes Updates strategy method signatures ( Written by Cursor Bugbot for commit c375949. Configure here. |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Autofix Details
Bugbot Autofix prepared a fix for the issue found in the latest run.
- ✅ Fixed: Stale "Run with --force" message before interactive prompt
- Removed the stale 'Run with --force to delete these items.' message from the preview path in runCleanWithItems, since the interactive confirmation prompt now handles user consent.
Or push these changes by commenting:
@cursor push 25546e5f38
Preview (25546e5f38)
diff --git a/cmd/entire/cli/clean.go b/cmd/entire/cli/clean.go
--- a/cmd/entire/cli/clean.go
+++ b/cmd/entire/cli/clean.go
@@ -246,7 +246,6 @@
fmt.Fprintln(w)
}
- fmt.Fprintln(w, "Run with --force to delete these items.")
return nil
}
diff --git a/cmd/entire/cli/clean_test.go b/cmd/entire/cli/clean_test.go
--- a/cmd/entire/cli/clean_test.go
+++ b/cmd/entire/cli/clean_test.go
@@ -143,9 +143,9 @@
t.Errorf("Should not list '%s', got: %s", paths.MetadataBranchName, output)
}
- // Should prompt to use --force
- if !strings.Contains(output, "--force") {
- t.Errorf("Expected '--force' prompt in output, got: %s", output)
+ // Should NOT contain stale --force message (interactive prompt handles confirmation)
+ if strings.Contains(output, "--force") {
+ t.Errorf("Should not contain '--force' message in interactive mode, got: %s", output)
}
// Branches should still exist (preview mode doesn't delete)This Bugbot Autofix run was free. To enable autofix for future PRs, go to the Cursor dashboard.
There was a problem hiding this comment.
Pull request overview
This PR adjusts the entire clean command’s user-facing output formatting (including pluralization and success markers) and updates tests accordingly, while also changing the default command flow to preview + interactive confirmation before deletion.
Changes:
- Update
cleanoutput formatting (✓ prefix, indentation tweaks, singular/plural “item(s)”). - Change
cleandefault behavior to show preview and then prompt for confirmation (with--forceskipping the prompt). - Refactor tests to call
runCleanwith acobra.Command(captured stdout) and to validate updated messages.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 6 comments.
| File | Description |
|---|---|
| cmd/entire/cli/clean.go | Adds confirmation flow, revises preview/deletion output strings and pluralization logic. |
| cmd/entire/cli/clean_test.go | Updates tests to match new output format and to invoke runClean via a test cobra command. |
|
@BugBot review |
c8b64a4 to
54d30a4
Compare
7286eb3 to
43aed19
Compare
- resume: drop single-quotes around branch name in "Switched to branch" (align with trail) - resume+rewind: replace "✓ Session: <id>" label style with verb-first "✓ Restored session <id>." - rewind: add missing ✓ confirmation header before "To continue this session, run:" for single-session case - trail: move "Note:" advisory message from stderr to stdout (align with rewind) Tests: update TestDisplayRestoredSessions_SingleSessionOutput for new header; add TestPrintMultiSessionResumeCommands_SingleSessionHasCheckmark for rewind single-session ✓ Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
… command formatting - Replace handleResetConfirmationError, handleResetDecline (reset.go) and handleTrailInteractionError (trail_cmd.go) with a single handleFormCancellation in utils.go; update clean.go inline handling to use it too - Extract printSessionCommand helper to utils.go, eliminating the duplicate 6-case switch in rewind.go and 4-case switch in resume.go - Remove 4 redundant helper-specific tests; replace with single TestHandleFormCancellation table test in utils_test.go - Fix integration tests: update "Session:" assertions to "Restored session" to match the output consistency rename from the prior commit Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

Consistent output across
clean,reset,rewind,resume,trail,doctor,and
status— cancellation messages, success prefixes (✓), branch nameformatting, indentation, and full session ID display
Note:advisory intrailfrom stderr to stdout to matchrewind(
handleResetConfirmationError,handleResetDecline,handleTrailInteractionError) into a singlehandleFormCancellationinutils.goprintSessionCommandhelper to replace duplicate 6-case and 4-caseswitches in
rewind.goandresume.goTest plan
resumesession header rename (Session:→Restored session)TestHandleFormCancellationtable test covers all cancellation pathsTestPrintMultiSessionResumeCommands_SingleSessionHasCheckmarkcovers newrewind ✓ header