CommunityCoding & Developmentgithub.com

shipkit

Manages the shared wt/* worktree, PR shipping, post-learn landing, branch audit, and Herdr tab cleanup workflow via the shipkit CLI. Use when creating or removing sibling worktrees, shipping or landing pull requests, auditing stale branches, or tidying finished Herdr agent tabs.

What is shipkit?

shipkit is a Claude Code agent skill that manages the shared wt/* worktree, PR shipping, post-learn landing, branch audit, and Herdr tab cleanup workflow via the shipkit CLI. Use when creating or removing sibling worktrees, shipping or landing pull requests, auditing stale branches, or tidying finished Herdr agent tabs.

Works with~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/ray-manaloto/shipkit/tree/HEAD/skills/shipkit

Installed? Explore more Coding & Development skills: steipete/bluebubbles, steipete/eightctl, steipete/blucli · View all 6 →

Ask in your favorite AI

Open a new chat with this agent skill pre-loaded.

Documentation

What does shipkit do?

shipkit provides one shared C++26 workflow for sibling wt/* git worktrees, re-runnable PR shipping, post-learn PR landing, branch auditing, and Herdr tab cleanup.

Setup

Install via mise (github:ray-manaloto/shipkit), or wrap repo tasks (mise run pr:ship, mise run pr:land, mise run worktree:new, mise run worktree:rm, mise run worktree:audit, mise run herdr:tidy) around the shipkit binary.

Commands and Non-Interactive Use

All commands accept --json for structured output.

CommandPurposeKey Flags
shipkit worktree new <slug>Create sibling <repo>-<slug> on wt/<slug> with PLAN_ID--base <ref>, --issue <n>
shipkit worktree rm <slug>Remove <repo>-<slug> and delete wt/<slug>--force
shipkit worktree auditClassify branches/worktrees (--doctor always exits 0)--repo <dir>, --base <ref>, --prune-merged, --doctor, --stale-days <d>
shipkit pr shipLocal gates, push, open/view PR, event wait, bot sweep, READY line--title <t>, --body-file <f>, --skip-local-gates, --wait-timeout <d>, --max-waits <n>, --required <csv>, --allow-skipped, --base <ref>
shipkit pr landVerify merge + post-task-learn, ff-pull base, land:post, keep .planning, remove worktree, herdr tidy--pr <n>, --skip-learn-check, --base <ref>
shipkit herdr tidyList or close finished Herdr agent tabs whose worktree is gone--apply, --cwd <dir>, --keep <csv>

Exit Codes (shipkit pr ship and shipkit pr land)

Exit CodeMeaning
0Ready to merge (pr ship) or landed cleanly (pr land)
1Required check failed (RED) or local gate failed
2Wait timed out (re-run shipkit pr ship to resume)
3Preflight refused (dirty tree, non-wt/* branch, auto-merge on, disabled workflow blocker, head moved, missing learn review)
4GitHub API unavailable after retries

Repo Detection and Private Repos (HTTP 403 Fallback)

shipkit detects the repository dynamically with gh repo view and derives the noreply merge author email from gh api user (unless overridden via .shipkit.toml or --author-email).

When repos/<owner>/<repo>/rules/branches/<base> returns HTTP 403 (such as private repos on GitHub Free) or has no ruleset checks, shipkit pr ship falls back in order:

  1. --required <csv>, PR_SHIP_REQUIRED / SHIPKIT_REQUIRED_CHECKS, or .shipkit.toml [ship] required_checks (repo-declared).
  2. Every check run on the PR head commit must complete success with at least one check run (head-check-runs; --allow-skipped or allow_skipped_checks = true also accepts skipped/neutral).

shipkit pr ship prints which source was used and refuses upfront if a disabled workflow produces a required check.

Per-Repository Hooks (.shipkit.toml or Local Mise Tasks)

Repos can declare hooks in .shipkit.toml or define local mise tasks (pr:ship:gates / ship:gates, pr:land:post / land:post, worktree:new:post / worktree:post):

[ship]
required_checks = ["Lint, Gates, and Tests"]
allow_skipped_checks = false

[hooks]
ship_gates = "mise run -q pr:ship:gates"
land_post = "mise run -q pr:land:post"
worktree_post = "mise run -q worktree:new:post"
  • ship:gates receives SHIPKIT_REPO, SHIPKIT_BRANCH, SHIPKIT_BASE, SHIPKIT_HEAD, and (when provided) SHIPKIT_PR_TITLE and SHIPKIT_PR_BODY_FILE.
  • land:post runs in the fast-forwarded main checkout with VIRTUAL_ENV, DOTFILES_DOCTOR_SCOPE, MISE_PROJECT_ROOT, and MISE_CONFIG_ROOT unset (warn-only).

Shipping Protocol

  1. Create a worktree with shipkit worktree new <slug>.
  2. Run repository review gates, then shipkit pr ship --title "<title>" --body-file <file>.
  3. shipkit pr ship never merges automatically. Once READY, re-run hk on the exact head and run the exact printed gh pr merge <n> -R <repo> --merge --match-head-commit <sha> --author-email <noreply> command.
  4. Record the post-task-learn review for PLAN_ID.
  5. Run shipkit pr land from the merged worktree (--skip-learn-check requires explicit owner approval).

Related Skills