# Finishing A Development Branch

> Use when implementation is complete to close branch/worktree with a disciplined decision flow (merge, PR, keep, discard) plus cleanup.

- Skill: `tomevault-io/finishing-a-development-branch-3` (Agent Skill, multi-file: 2 files)
- Install (CLI): `npx skillmds@latest add tomevault-io/finishing-a-development-branch-3`
- Raw SKILL.md: https://api.skillmd.com/api/skills/tomevault-io/finishing-a-development-branch-3/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Productivity
- Author: tomevault-io (https://skillmd.com/u/tomevault-io)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/tomevault-io/finishing-a-development-branch-3

---


# Finishing a Development Branch

Use this at the end of implementation to close work cleanly and avoid abandoned branches/worktrees.

## Step 1: Verify before finish

Run relevant verification commands first (build/lint/repro command as applicable). Do not proceed with failing verification.

## Step 2: Present exactly 4 options

1. Merge locally into base branch
2. Push and create PR
3. Keep branch/worktree for later
4. Discard branch/worktree

## Step 3: Execute chosen path safely

- For merge/PR: ensure base branch context is correct.
- For discard: require explicit confirmation.
- Never force push unless explicitly requested.

## Step 4: Worktree cleanup rules

- Merge/Discard: cleanup worktree.
- Keep/PR: keep worktree unless user asks to remove it.

## Expected output

- Selected option
- Commands executed
- Current branch/worktree status
- Any follow-up action required

---
> Source: [J-Pster/Psters_AI_Workflow](https://github.com/J-Pster/Psters_AI_Workflow) — distributed by [TomeVault](https://tomevault.io).
<!-- tomevault:4.0:skill_md:2026-06-22 -->

