ship-pr

Installation
SKILL.md

Ship PR

Escort finished work from the current worktree to a merged pull request on the repository's forge (the service that hosts the repository: GitHub, Forgejo, or Gitea).

Forge and tool

Read the host from the origin remote URL. Treat github.com as GitHub. For any other host, run gh auth status --hostname <host>, and run tea whoami with the tea login configured for that host. Use the one tool whose probe succeeds. If neither probe or both probes succeed, stop and ask the user which forge and tool to use.

Use gh on GitHub. Use tea on Forgejo or Gitea. Where this skill names a gh command, run the tea equivalent:

  • tea whoami verifies authentication.
  • tea pr ls lists open pull requests. tea pr create creates a pull request.
  • tea api <endpoint> sends an authenticated request to the forge API. tea fills {owner} and {repo} from the repository context. Replace <index>, <sha>, and <base> yourself with the pull request index, the head commit SHA, and the percent-encoded base branch name.
  • tea api /repos/{owner}/{repo}/pulls/<index> returns state, head.sha, mergeable, merged, and merged_at.
  • tea api /repos/{owner}/{repo}/pulls/<index>/reviews returns each review with its state, dismissed, and stale flags.
  • tea api /repos/{owner}/{repo}/commits/<sha>/status returns the combined commit status.
  • tea api /repos/{owner}/{repo}/branches/<base> returns the base branch with its effective protection: protected, required_approvals, enable_status_check, and status_check_contexts.

On Forgejo or Gitea, decide the gates from these responses. A review gate is open when a non-dismissed review has state REQUEST_CHANGES, or when the count of reviews with state APPROVED, dismissed false, and stale false is below required_approvals. A status gate is open when enable_status_check is true and any context in status_check_contexts is absent from the combined status or is not success. These fields do not cover every protection policy, for example official-review requests or approval whitelists. When they do not explain a refusal that the forge reports, report that gate as unverified and keep polling.

Installs
1
Repository
mintuz/skills
GitHub Stars
28
First Seen
Sep 3, 2026
ship-pr — mintuz/skills