From flowstate
Use when implementation is complete and all tests pass — guides branch completion by presenting structured options for merge, PR, or cleanup.
npx claudepluginhub c-reichert/flowstate --plugin flowstateThis skill uses the workspace's default tool permissions.
**Core principle:** Verify tests -> Present options -> Execute choice -> Clean up.
Searches, retrieves, and installs Agent Skills from prompts.chat registry using MCP tools like search_skills and get_skill. Activates for finding skills, browsing catalogs, or extending Claude.
Searches prompts.chat for AI prompt templates by keyword or category, retrieves by ID with variable handling, and improves prompts via AI. Use for discovering or enhancing prompts.
Dispatches parallel agents to independently tackle 2+ tasks like separate test failures or subsystems without shared state or dependencies.
Core principle: Verify tests -> Present options -> Execute choice -> Clean up.
Invoke the flowstate:verification-before-completion skill. Run the full test suite. Read output. Confirm zero failures.
If tests fail: Stop. Report failures. Do NOT proceed to Step 2.
Use AskUserQuestion to present exactly these 4 options:
Implementation complete. All tests pass. What would you like to do?
1. Merge back to <base-branch> 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?
Determine <base-branch> first:
git merge-base HEAD main 2>/dev/null || git merge-base HEAD master 2>/dev/null
git checkout <base-branch>
git pull
git merge <feature-branch>
# Verify tests on merged result
<test command>
# If tests pass
git branch -d <feature-branch>
See the requesting-code-review skill for what to include in the PR description.
git push -u origin <feature-branch>
gh pr create --title "<title>" --body "$(cat <<'EOF'
## Summary
<what was built and why>
## Testing
<tests added, pass evidence, coverage summary>
## Post-Deploy Monitoring
<what to monitor, healthy signals, rollback triggers>
EOF
)"
Report the PR URL.
Report: "Keeping branch <name>. Worktree preserved at <path>."
Do NOT clean up worktree or branch.
Require typed confirmation. Show what will be deleted (branch, commits, worktree). Wait for exact "discard" confirmation, then:
git checkout <base-branch>
git branch -D <feature-branch>
Option 3 preserves the worktree. For all others:
git worktree list # check if in a worktree
git worktree remove <worktree-path> # if applicable
For Option 2 (PR created), ask: "Delete local feature branch, or keep it?"
| Option | Merge | Push | Keep Worktree | Cleanup Branch |
|---|---|---|---|---|
| 1. Merge locally | yes | - | - | yes |
| 2. Create PR | - | yes | - | ask |
| 3. Keep as-is | - | - | yes | - |
| 4. Discard | - | - | - | yes (force) |