finishing-a-development-branch

Verify tests and select merge, PR, or cleanup for a development branch.

4|Updated Dec 7, 2020
One-click install
npx skills add https://github.com/charly3pins/dotfiles --skill finishing-a-development-branch-charly3pins
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: finishing-a-development-branch
Source: https://github.com/charly3pins/dotfiles/tree/main/.config/opencode/skills/finishing-a-development-branch
Command: npx skills add https://github.com/charly3pins/dotfiles --skill finishing-a-development-branch-charly3pins

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires gh CLI.

What problem does it solve?

Completing development work often involves ambiguous decisions about merging, creating pull requests, or cleaning up, leading to errors or incomplete workflows.

Core Features & Use Cases

  • Test Verification Gate: Ensures all tests pass before presenting integration options, preventing broken code merges.
  • Structured Integration Options: Presents four clear choices: merge locally, push and create PR, keep as-is, or discard work.
  • Automated Cleanup: Handles branch deletion and worktree removal based on the chosen option, streamlining the post-development process.
  • Use Case: After completing a feature and ensuring all tests pass, use this skill to guide the final steps of integrating your work, whether by merging to main, creating a pull request, or discarding the branch.

Quick Start

I have completed my development work and all tests pass. Guide me through the process of finishing this development branch.

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 finish a development branch after tests pass?

Finishing a development branch involves verifying tests pass, then choosing between merging locally, creating a pull request, keeping the branch as-is, or discarding it. This Skill automates that decision process and executes the corresponding git commands, including optional cleanup of branch and worktree.

What's the best way to merge a feature branch to main or master?

After test verification, you can merge directly to your base branch using git merge, or push and create a pull request via gh CLI for code review. This Skill presents both options and handles the merge or PR creation based on your choice.

How do I clean up a development branch and worktree after merging?

Branch cleanup removes local and remote branch references after integration; worktree cleanup removes linked working directories. This Skill automates both based on your chosen merge or discard option, streamlining post-development tasks.

Can I automate branch integration decisions with git and gh CLI?

Yes. This Skill automates the full decision workflow for integrating feature branches by verifying tests, determining your base branch, presenting structured options, and executing the appropriate git and gh CLI commands without manual steps.

What happens if tests fail before finishing a development branch?

This Skill enforces a test verification gate—it halts the integration process if tests fail, preventing broken code from merging. You must resolve test failures before the Skill presents integration options.

Does this Skill work with common CI workflows and base branches?

Yes. This Skill integrates across standard CI workflows and common base branches like main or master, making it compatible with typical development environments without special configuration.