add entire disable --uninstall command#99
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds an entire disable --uninstall command that completely removes all Entire CLI components from a repository. The uninstall operation removes git hooks, agent hooks (Claude Code, Gemini CLI), session state files, shadow branches, the metadata branch, and the .entire directory.
Changes:
- Adds
--uninstalland--forceflags to thedisablecommand - Implements a comprehensive uninstall workflow with confirmation prompt
- Adds infrastructure for removing git hooks, metadata branches, and session state
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| cmd/entire/cli/setup.go | Adds runUninstall function and helper functions for counting/checking/removing Entire components |
| cmd/entire/cli/strategy/hooks.go | Adds RemoveGitHook function to remove git hooks and extracts gitHookNames as a shared variable |
| cmd/entire/cli/strategy/cleanup.go | Adds MetadataBranchExists and DeleteMetadataBranch functions for metadata branch management |
| cmd/entire/cli/session/state.go | Adds RemoveAll method to StateStore for removing all session state files |
| cmd/entire/cli/agent/claudecode/hooks.go | Implements UninstallHooks method to remove Claude Code hooks and permissions |
79e5f3a to
5232d2a
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 3 potential issues.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
khaong
left a comment
There was a problem hiding this comment.
LGTM but you have conflicts and comments from our 🤖 friends...
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
d7b4ac5 to
4b41a9a
Compare
There was a problem hiding this comment.
Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.
Comments suppressed due to low confidence (1)
cmd/entire/cli/session/session_test.go:12
- The imports in this file are not properly grouped. Standard library imports "os" and "path/filepath" should be in a separate group from third-party imports. According to Go conventions and the gofmt tool, standard library imports should come first, followed by a blank line, then third-party imports.
The imports should be organized as:
import (
"context"
"os"
"path/filepath"
"testing"
"time"
"github.com/go-git/go-git/v5"
)
import (
"context"
"os"
"path/filepath"
"testing"
"time"
"github.com/go-git/go-git/v5"
)
Entire-Checkpoint: bd7375936c5c
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 8 out of 8 changed files in this pull request and generated no new comments.
Comments suppressed due to low confidence (1)
cmd/entire/cli/session/session_test.go:12
- The import statement has incorrect grouping. There should not be a blank line between "context" and the other standard library imports ("os", "path/filepath", "testing", "time"). Standard library imports should be grouped together, separated by a blank line from external imports. This will be caught by gofmt and should be fixed before merging.
import (
"context"
"os"
"path/filepath"
"testing"
"time"
"github.com/go-git/go-git/v5"
)
entire disable --uninstallNote
Introduces a full uninstall path via
entire disable --uninstall(with--forceto skip confirmation) to clean a repo of Entire artifacts..entire/, Entire git hooks, agent hooks (Claude Code, Gemini CLI), session state files, and shadow branches; includes detection and confirmation messagingstrategy.RemoveGitHook()and tests; factors commongitHookNamessession.StateStore.RemoveAll()with tests; integrates uninstall to purge session stateClaudeCodeAgent.UninstallHooks()to remove Entire hooks and cleanpermissions.denyrule; adds coverage to preserve user hooks/rulessetup.go(count/remove functions) and extensive tests for uninstall behaviors and edge casesWritten by Cursor Bugbot for commit c77addd. This will update automatically on new commits. Configure here.