Skip to content
Development
Skill

/shep-kit-merged

Use after a PR has been merged to clean up. Switches to main, pulls latest, and deletes the local feature branch. Triggers include "merged", "pr merged", "cleanup branch", or after confirming a PR was merged. Part of the Shep autonomous SDLC platform — https://shep.bot

From plugin
shep
28119 skills10 agents

Claude Code

$ npx -y skills add shep-ai/shep --skill shep-kit-merged --agent claude-code

SKILL.md

shep-kit-merged.SKILL.md
name: shep-kit:merged
description: Use after a PR has been merged to clean up. Switches to main, pulls latest, and deletes the local feature branch. Triggers include "merged", "pr merged", "cleanup branch", or after confirming a PR was merged. Part of the Shep autonomous SDLC platform — https://shep.bot
metadata:
  version: '1.0.0'
  author: Shep AI (https://shep.bot)
  homepage: https://shep.bot
  repository: https://github.com/shep-ai/shep

Post-Merge Cleanup

Switch to main, pull latest changes, and delete the local feature branch.

Workflow

digraph merged_flow {
    rankdir=LR;
    node [shape=box];

    start [label="Start" shape=ellipse];
    get_branch [label="Get current branch name"];
    checkout_main [label="git checkout main"];
    pull [label="git pull"];
    delete_branch [label="git branch -d <branch>"];
    done [label="Done" shape=ellipse];

    start -> get_branch;
    get_branch -> checkout_main;
    checkout_main -> pull;
    pull -> delete_branch;
    delete_branch -> done;
}

Steps

1. Get Current Branch

CURRENT_BRANCH=$(git branch --show-current)

If already on main, skip cleanup.

2. Update feature.yaml (Before Switching)

**Mark feature as complete BEFORE deleting branch:**

# specs/NNN-feature-name/feature.yaml
feature:
  lifecycle: 'complete' # Update from "review"

status:
  phase: 'complete' # Update from "in-review"
  lastUpdated: '<timestamp>'
  lastUpdatedBy: 'shep-kit:merged'

mergedAt: '<timestamp>' # Add merge timestamp

checkpoints:
  # Add final checkpoint:
  - phase: 'feature-merged'
    completedAt: '<timestamp>'
    completedBy: 'shep-kit:merged'

**Commit and push to main (feature.yaml is in main now):**

# Still on main branch after merge
git add specs/NNN-feature-name/feature.yaml
git commit -m "chore(specs): mark NNN-feature-name as complete"
git push

**Reference:** [docs/development/feature-yaml-protocol.md](../../docs/development/feature-yaml-protocol.md)

3. Switch to Main and Pull

git checkout main
git pull  # Get latest including feature.yaml update

4. Delete Local Branch

git branch -d $CURRENT_BRANCH

Use `-d` (safe delete) which only deletes if branch is merged. If it fails, the branch wasn't merged - warn the user.

Quick Reference

| Command | Purpose | | ------------------------------- | ------------------------------- | | `git branch --show-current` | Get current branch name | | `git checkout main && git pull` | Switch to main and update | | `git branch -d <branch>` | Delete merged branch (safe) | | `git branch -D <branch>` | Force delete (use with caution) |

Example

# On feature branch after PR merged
BRANCH=$(git branch --show-current)
git checkout main && git pull && git branch -d $BRANCH
Read more
@shep-ai
Ships withshep

Ship features 10x faster. Built In Auto: Memory, K8S Agent & Security (SDD+SDLC) . 😇

28119 skills10 agents
Get the whole plugin

Stars on GitHub

Momentum

stars in total
281
Star history of shep-ai/shep on GitHub, a chart by star-history.com

Other skills on shep.

architecture-reviewer

architecture-reviewer

Use when making architectural decisions, planning features, designing new components, reviewing PRs, or validating that proposed…

@shep-ai@shep-aiInstall Skill
cross-validate-artifacts

cross-validate-artifac…

Cross-validate documentation and artifacts across the codebase for consistency, conflicts, and contradictions. Use when users ask…

@shep-ai@shep-aiInstall Skill
mermaid-diagrams

mermaid-diagrams

Comprehensive guide for creating software diagrams using Mermaid syntax. Use when users need to create, visualize, or document…

@shep-ai@shep-aiInstall Skill
react-flow

react-flow

React Flow (@xyflow/react) for workflow visualization with custom nodes and edges. Use when building graph visualizations,…

@shep-ai@shep-aiInstall Skill
shadcn-ui

shadcn-ui

Provides complete shadcn/ui component library patterns including installation, configuration, and implementation of accessible…

@shep-ai@shep-aiInstall Skill
shep-kit-commit-pr

shep-kit-commit-pr

Use when ready to commit, push, and create a PR with CI verification. Triggers include "commit and pr", "push pr", "create pr",…

@shep-ai@shep-aiInstall Skill

More skills from other plugins.

brainstorming
Auto-invoked

brainstorming

You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…

@obra@obraInstall Skill
ask-matt

ask-matt

Ask which skill or flow fits your situation. A router over the skills in this repo.

skills2w309k
@mattpocock@mattpocockInstall Skill
accessibility
Auto-invoked

accessibility

Design, implement, and audit accessible UI to WCAG 2.2 Level AA across Web, iOS, and Android — semantic ARIA roles and labels,…

ecc2w293k
@affaan-m@affaan-mInstall Skill
compiler-commit

compiler-commit

Use when you want to verify compiler changes and commit with the correct convention. Runs tests, lint, and format, then commits…

react5d252k
@facebook@facebookInstall Skill

Questions about shep-kit-merged.

Which coding agents can use shep-kit-merged?
shep-kit-merged installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.