Skip to content

feat(git): add batch branch deletion support#807

Merged
horza-bora merged 1 commit intomainfrom
feat/git-batch-branch-delete
Apr 12, 2026
Merged

feat(git): add batch branch deletion support#807
horza-bora merged 1 commit intomainfrom
feat/git-batch-branch-delete

Conversation

@Dave-London
Copy link
Copy Markdown
Owner

Summary

  • The branch tool's delete param now accepts both a single string and an array of branch names, enabling batch deletion in one call (closes feat(git): batch branch deletion support #802)
  • The forceDelete param similarly accepts an array of branch names for batch force-deletion
  • Uses z.preprocess(coerceJsonArray, ...) for MCP client compatibility with JSON-stringified arrays
  • Each branch name is validated with assertNoFlagInjection before passing to git branch -d/-D

Test plan

  • Single branch deletion still works (backward compat)
  • Array of branches deletion works
  • Mixed success/failure (one exists, one doesn't) returns error
  • Force-delete with array of branch names works
  • Existing forceDelete tests still pass (boolean and string variants)

Fixes #802

Dave-London added a commit that referenced this pull request Apr 12, 2026
- Add explicit timeout parameters (180_000 for beforeAll, 30_000 for
  afterAll) to the write-tool integration test hooks in server-git,
  preventing McpError: Connection closed on slow CI environments
- Apply the same timeout fix across all 13 server integration test files
- Add tests for batch branch deletion flag injection in delete array
- Add tests for forceDelete string param (PR #807)
- Add tests verifying dash-prefixed build args pass validation (PR #805)
- Add tests for PATH augmentation: non-existent paths skipped, and
  end-to-end verification of augmented paths (PR #808)
@horza-bora horza-bora merged commit 882d2ec into main Apr 12, 2026
11 checks passed
@horza-bora horza-bora deleted the feat/git-batch-branch-delete branch April 12, 2026 06:05
@pare-ci-bot pare-ci-bot bot mentioned this pull request Apr 12, 2026
Dave-London added a commit that referenced this pull request Apr 12, 2026
- Add explicit timeout parameters (180_000 for beforeAll, 30_000 for
  afterAll) to the write-tool integration test hooks in server-git,
  preventing McpError: Connection closed on slow CI environments
- Apply the same timeout fix across all 13 server integration test files
- Add tests for batch branch deletion flag injection in delete array
- Add tests for forceDelete string param (PR #807)
- Add tests verifying dash-prefixed build args pass validation (PR #805)
- Add tests for PATH augmentation: non-existent paths skipped, and
  end-to-end verification of augmented paths (PR #808)
Dave-London added a commit that referenced this pull request Apr 12, 2026
- Add explicit timeout parameters (180_000 for beforeAll, 30_000 for
  afterAll) to the write-tool integration test hooks in server-git,
  preventing McpError: Connection closed on slow CI environments
- Apply the same timeout fix across all 13 server integration test files
- Add tests for batch branch deletion flag injection in delete array
- Add tests for forceDelete string param (PR #807)
- Add tests verifying dash-prefixed build args pass validation (PR #805)
- Add tests for PATH augmentation: non-existent paths skipped, and
  end-to-end verification of augmented paths (PR #808)
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.

feat(git): batch branch deletion support

2 participants