finishing-a-development-branch

Verify test results before presenting four branch integration options.

35|5|Updated Sep 20, 2025
One-click install
npx skills add https://github.com/zhanglongxiao111/indesign-cli --skill finishing-a-development-branch-zhanglongxiao111
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: finishing-a-development-branch
Source: https://github.com/zhanglongxiao111/indesign-cli/tree/main/.codex/skills/finishing-a-development-branch
Command: npx skills add https://github.com/zhanglongxiao111/indesign-cli --skill finishing-a-development-branch-zhanglongxiao111

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It prevents teams from merging or deleting branches without first confirming that the full test suite passes and making an explicit, structured decision about what to do next.

Core Features & Use Cases

  • Test-first completion gate: Forces a “verify tests pass” step before offering any merge/PR/discard choices, reducing the risk of shipping broken changes.
  • Four-option structured workflow: Presents exactly four concise actions (merge locally, push+PR, keep branch, discard) to eliminate ambiguous “what should I do?” loops.
  • Safe cleanup and confirmation: Removes worktrees and feature branches when appropriate, and requires typed confirmation before permanently discarding commits/branch/worktree.

Quick Start

Ask the AI to finish and decide how to integrate your current development branch after you run tests and tell it whether they passed.

Frequently Asked Questions about finishing-a-development-branch

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I safely finish a Git development branch after tests pass?

To safely finish a Git development branch, enforce a test verification step first, then choose from four options: merge locally, push for a pull request, keep the branch, or discard it. Worktree cleanup follows automatically for merge, PR, or discard actions.

What are the options for integrating a development branch in Git?

Integrating a development branch offers exactly four structured options: merge locally, push and create a pull request, preserve the branch indefinitely, or discard it. This eliminates ambiguous decision loops after completing your work.

Can I delete a Git branch and worktree without typed confirmation?

No, discarding a branch and its worktree requires explicit typed confirmation. This safety mechanism prevents permanently losing commits and ensures you intentionally approve the destructive deletion action.

How to prevent merging a Git branch with failing tests?

Prevent merging broken code by enforcing a test-first completion gate. This workflow requires verifying that the full test suite passes before presenting any merge, pull request, keep, or discard options for your feature branch.

Does finishing a branch clean up worktrees automatically when I open a pull request?

Yes, worktree cleanup occurs automatically when you choose to merge locally, push for a pull request, or discard the branch. If you select to preserve the branch, the worktree is retained without modification.

What is the best way to manage branch completion and avoid unsafe Git integration?

The best way to avoid unsafe Git integration is using a structured branch completion workflow that mandates test verification and provides four explicit actions. This prevents accidental merges or deletions by requiring typed confirmation for destructive operations.