AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified MIT Self-run

Finishing A Development Branch

skill-flydev-fr-mormot2-superpowers-finishing-a-development-branch · by flydev-fr

Use when implementation is complete, all tests pass, and you need to decide how to integrate the work - guides completion of development work by presenting structured options for merge, PR, or cleanup

No reviews yet
0 installs
38 views
0.0% view→install

Install

$ agentstack add skill-flydev-fr-mormot2-superpowers-finishing-a-development-branch

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-flydev-fr-mormot2-superpowers-finishing-a-development-branch)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
3mo ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Finishing A Development Branch? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Finishing a Development Branch

Overview

Guide completion of development work by presenting clear options and handling chosen workflow.

Core principle: Verify tests → Present options → Execute choice → Clean up.

Announce at start: "I'm using the finishing-a-development-branch skill to complete this work."

The Process

Step 1: Verify Tests

Before presenting options, verify tests pass:

# Run project's test suite
npm test / cargo test / pytest / go test ./...

If tests fail:

Tests failing ( failures). Must fix before completing:

[Show failures]

Cannot proceed with merge/PR until tests pass.

Stop. Don't proceed to Step 2.

If tests pass: Continue to Step 2.

Step 2: Determine Base Branch

# Try common base branches
git merge-base HEAD main 2>/dev/null || git merge-base HEAD master 2>/dev/null

Or ask: "This branch split from main - is that correct?"

Step 3: Present Options

Present exactly these 4 options:

Implementation complete. What would you like to do?

1. Merge back to  locally
2. Push and create a Pull Request
3. Keep the branch as-is (I'll handle it later)
4. Discard this work

Which option?

Don't add explanation - keep options concise.

Step 4: Execute Choice

Option 1: Merge Locally
# Switch to base branch
git checkout 

# Pull latest
git pull

# Merge feature branch
git merge 

# Verify tests on merged result

# If tests pass
git branch -d 

Then: Cleanup worktree (Step 5)

Option 2: Push and Create PR
# Push branch
git push -u origin 

# Create PR
gh pr create --title "" --body "$(cat 

## Test Plan
- [ ] 
EOF
)"

Then: Cleanup worktree (Step 5)

Option 3: Keep As-Is

Report: "Keeping branch . Worktree preserved at ."

Don't cleanup worktree.

Option 4: Discard

Confirm first:

This will permanently delete:
- Branch 
- All commits: 
- Worktree at 

Type 'discard' to confirm.

Wait for exact confirmation.

If confirmed:

git checkout 
git branch -D 

Then: Cleanup worktree (Step 5)

Step 5: Cleanup Worktree

For Options 1, 2, 4:

Check if in worktree:

git worktree list | grep $(git branch --show-current)

If yes:

git worktree remove 

For Option 3: Keep worktree.

Quick Reference

| Option | Merge | Push | Keep Worktree | Cleanup Branch | |--------|-------|------|---------------|----------------| | 1. Merge locally | ✓ | - | - | ✓ | | 2. Create PR | - | ✓ | ✓ | - | | 3. Keep as-is | - | - | ✓ | - | | 4. Discard | - | - | - | ✓ (force) |

Common Mistakes

Skipping test verification

  • Problem: Merge broken code, create failing PR
  • Fix: Always verify tests before offering options

Open-ended questions

  • Problem: "What should I do next?" → ambiguous
  • Fix: Present exactly 4 structured options

Automatic worktree cleanup

  • Problem: Remove worktree when might need it (Option 2, 3)
  • Fix: Only cleanup for Options 1 and 4

No confirmation for discard

  • Problem: Accidentally delete work
  • Fix: Require typed "discard" confirmation

Red Flags

Never:

  • Proceed with failing tests
  • Merge without verifying tests on result
  • Delete work without confirmation
  • Force-push without explicit request

Always:

  • Verify tests before offering options
  • Present exactly 4 options
  • Get typed confirmation for Option 4
  • Clean up worktree for Options 1 & 4 only

Integration

Called by:

  • subagent-driven-development (Step 7) - After all tasks complete
  • executing-plans (Step 5) - After all batches complete

Pairs with:

  • using-git-worktrees - Cleans up worktree created by that skill

Pascal / mORMot2 Addendum

> When this section applies: the session is operating on a Pascal project (the > PASCAL_PROJECT=1 env was exported by the mormot2-superpowers session-start hook). > If PASCAL_PROJECT is unset, ignore this section.

Before any merge / PR / cleanup decision, run the dual verification gate:

1. Both compilers, when applicable

If both .dproj and .lpi exist in the project tree, build both:

/delphi-build
/fpc-build

Either's failure blocks the finish. Pin to one compiler in .claude/mormot2.config.json only if the project explicitly drops the other target.

2. TSynTestCase suite

Run /mormot2-test. Exit 0 required. Do not finalise the branch on a yellow test run.

3. mORMot 2 regression suite (if you touched mORMot 2 itself)

If your branch modifies the mORMot 2 source tree (rare; only happens when working in $MORMOT2_PATH), run mORMot 2's own regression suite. Otherwise skip.

4. Cleanup

After merge or discard, remove the worktree's .dcu/.ppu build artefacts. Do NOT delete $MORMOT2_PATH - it is shared.

Decision matrix

  • All gates green + change is bug fix: merge to main.
  • All gates green + change is feature: open PR (or merge to main if solo).
  • Test suite red: keep branch, do not merge, document the blocker in the branch description.
  • Build red on one compiler only: pin compiler in config OR fix the broken target before merging.

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.