finishing-a-development-branch

Verify tests and present four Git branch completion options.

6|1|Updated Nov 8, 2025
One-click install
npx skills add https://github.com/LEEI1337/phantom-neural-cortex --skill finishing-a-development-branch-leei1337
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: finishing-a-development-branch
Source: https://github.com/LEEI1337/phantom-neural-cortex/tree/main/.claude/skills/finishing-a-development-branch
Command: npx skills add https://github.com/LEEI1337/phantom-neural-cortex --skill finishing-a-development-branch-leei1337

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill provides a structured workflow for completing development work on a Git branch, ensuring all tests pass and offering clear options for integration (merge, PR, discard) or preservation. It automates the final steps of a feature lifecycle, preventing errors and ensuring proper cleanup, saving developer time and maintaining repository hygiene.

Core Features & Use Cases

  • Test Verification: Mandates running and passing all tests before any integration options are presented.
  • Structured Options: Presents exactly four clear choices: merge locally, push and create PR, keep as-is, or discard work.
  • Automated Execution: Executes the chosen Git command (merge, push, delete branch) and handles worktree cleanup.
  • Safety Confirmation: Requires explicit confirmation before discarding work to prevent accidental data loss.
  • Use Case: After completing a new feature and verifying all tests pass, use this skill to seamlessly create a pull request, ensuring your changes are properly integrated and your development environment is cleaned up.

Quick Start

I've finished implementing the user profile update. Use the finishing-a-development-branch skill to complete this work.

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 merge a Git branch after tests pass?

Merging a Git branch after tests pass integrates your completed work into the base branch. This skill verifies all tests pass, identifies the base branch automatically, and executes the merge command locally or via pull request, ensuring proper integration and cleanup.

What's the best way to clean up a development branch after completing a feature?

Branch cleanup after feature completion involves running tests, choosing an integration method (merge, PR, keep, or discard), and executing the corresponding Git commands. This skill automates those steps, deleting the branch or preserving it based on your choice.

How do I create a pull request from a completed development branch?

Creating a pull request from a completed branch requires verifying tests pass, determining the base branch, and pushing the branch with PR creation. This skill automates test verification and presents the pull request option alongside merge, keep, and discard alternatives.

Can I discard a development branch safely without losing work accidentally?

Discarding a branch safely requires explicit confirmation to prevent accidental data loss. This skill mandates confirmation before executing branch deletion, ensuring you intentionally choose to discard your work before cleanup occurs.

What happens if tests fail before finishing a development branch?

If tests fail, the workflow halts and does not present integration options. This skill mandates all tests pass before offering merge, PR, keep, or discard choices, preventing incomplete or broken work from integrating.

Do I need to manually determine the base branch when merging?

Manual base branch determination is not required. This skill derives the base branch automatically using Git merge-base, eliminating the need to manually identify where your branch should merge and reducing integration errors.