Skip to content

fix(git-guards): auto-allow git worktree remove#54

Merged
JacobPEvans merged 2 commits intomainfrom
fix/allow-git-worktree-remove
Feb 25, 2026
Merged

fix(git-guards): auto-allow git worktree remove#54
JacobPEvans merged 2 commits intomainfrom
fix/allow-git-worktree-remove

Conversation

@JacobPEvans
Copy link
Owner

@JacobPEvans JacobPEvans commented Feb 25, 2026

Summary

  • Removes git worktree remove from the ASK_GIT confirmation list in git-permission-guard.py
  • git worktree remove is a routine, low-risk operation in the standard worktree workflow and no longer requires user confirmation
  • Falls through to the default silent allow (sys.exit(0)) at the end of the script

Test plan

  • Verified git worktree remove exits silently (allow) with no output
  • Verified other ASK_GIT entries (e.g., git reset) still trigger confirmation prompts

🤖 Generated with Claude Code


Important

Removes git worktree remove from confirmation list in git-permission-guard.py, allowing silent execution.

  • Behavior:
    • Removes git worktree remove from ASK_GIT in git-permission-guard.py, allowing it to execute without user confirmation.
    • Falls through to default silent allow (sys.exit(0)) for git worktree remove.
  • Testing:
    • Verified git worktree remove exits silently with no output.
    • Confirmed other ASK_GIT entries still trigger confirmation prompts.

This description was created by Ellipsis for 3d535a5. You can customize this summary. It will automatically update as commits are pushed.

Removes worktree remove from ASK_GIT so it's silently allowed.
This is a routine low-risk operation in the worktree workflow.

(claude)
Copilot AI review requested due to automatic review settings February 25, 2026 12:30
Copy link

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Important

Looks good to me! 👍

Reviewed everything up to 3d535a5 in 7 seconds. Click for details.
  • Reviewed 12 lines of code in 1 files
  • Skipped 0 files when reviewing.
  • Skipped posting 0 draft comments. View those below.
  • Modify your settings and rules to customize what types of comments Ellipsis leaves. And don't forget to react with 👍 or 👎 to teach Ellipsis.

Workflow ID: wflow_LGzOGbDwoXaFT4at

You can customize Ellipsis by changing your verbosity settings, reacting with 👍 or 👎, replying to comments, or adding code review rules.

@gemini-code-assist
Copy link

Summary of Changes

Hello @JacobPEvans, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request streamlines the git worktree remove operation by eliminating the need for user confirmation. Recognizing git worktree remove as a routine and low-risk command within the standard worktree workflow, this change improves developer experience by allowing the command to proceed silently, aligning with its intended use as a safe operation.

Highlights

  • Automated git worktree remove: The git worktree remove command has been removed from the ASK_GIT confirmation list in git-permission-guard.py. This change allows the command to execute silently without prompting the user, as it is considered a routine and low-risk operation.
Changelog
  • git-guards/scripts/git-permission-guard.py
    • Removed worktree remove from the ASK_GIT confirmation list.
Activity
  • No human activity has been recorded on this pull request yet.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refines the git-guards permission system by removing git worktree remove from the confirmation list, recognizing it as a routine, low-risk cleanup operation in the standard worktree workflow rather than a potentially dangerous command requiring user confirmation.

Changes:

  • Removes git worktree remove from the ASK_GIT confirmation list in git-permission-guard.py

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request aims to auto-allow git worktree remove by removing it from the confirmation list. While I agree that the non-forced version of the command is low-risk, the forced version (--force or -f) can cause data loss. My review includes a suggestion to refine this change to only prompt for confirmation on the forced variants, which aligns with the goal of allowing the safe command while maintaining protection against destructive operations.

Plain `git worktree remove` is safe (fails if uncommitted changes exist),
so it no longer needs confirmation. The forced variants (`-f`/`--force`)
can discard uncommitted changes and now prompt for confirmation.

(claude)
@JacobPEvans JacobPEvans merged commit 9d0bec6 into main Feb 25, 2026
5 checks passed
@JacobPEvans JacobPEvans deleted the fix/allow-git-worktree-remove branch February 25, 2026 12:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants