From mygit
REQUIRED when two conditions are met: (1) an existing pull request is referenced — via "my PR", "a PR", "PR #N", a GitHub PR URL, or "opened a PR", AND (2) the user wants it fixed, unblocked, or monitored. Problem signals: CI red, checks failing, test/lint/type/build errors, merge conflicts, "blocked", "not merging", "make it mergeable". Monitoring signals: babysit, watch, keep an eye on, auto-merge, "until it lands". Reads CI logs, pushes fixes, rebases conflicts, enables auto-merge. SKIP when: no existing PR is involved, user wants to create a new PR, cherry-pick, or do git operations on a branch without a PR.
How this skill is triggered — by the user, by Claude, or both
Slash command
/mygit:babysit-prThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Monitors a pull request and autonomously maintains it: fixes failed CI checks, rebases to resolve merge conflicts, and enables auto-merge. Designed for repeated invocation via `/loop` — each call is one check-and-fix pass.
Monitors a pull request and autonomously maintains it: fixes failed CI checks, rebases to resolve merge conflicts, and enables auto-merge. Designed for repeated invocation via /loop — each call is one check-and-fix pass.
Determine the target PR from (in priority order):
gh pr view --json number,titleEach invocation runs through these steps in order. After each push, wait for checks to complete before continuing.
gh pr view <PR> --json number,title,state,mergeable,baseRefName,headRefName,autoMergeRequest
gh pr checks <PR>
If the PR is merged or closed, report final state and stop.
If any checks are failing:
gh run list --branch <head-branch> --status failure --limit 5 --json databaseId,name,conclusion
gh run view <run-id> --log-failed
git add <specific-files>
git commit -m "fix(ci): <description>"
git push
gh pr checks <PR> --watch
If mergeable is CONFLICTING:
git fetch origin
git rebase origin/<base-branch>
git add <resolved-files>
git rebase --continue
git push --force-with-lease
gh pr checks <PR> --watch
If all checks are passing and auto-merge is not yet enabled (autoMergeRequest is null):
gh pr merge <PR> --auto --squash
Output a single status line:
| Status | Meaning |
|---|---|
| All checks passing, auto-merge enabled | Nothing to do — PR will merge when ready |
| Fixed <description>, checks green, auto-merge enabled | PR is ready to merge |
| Rebased onto <base>, checks green, auto-merge enabled | PR is ready to merge |
| Could not fix: <reason> | Needs user intervention |
gh pr checks <PR> --watch after pushing, then continue the workflow based on the result.--force-with-lease, never --force./loop. When there's nothing to do, report status and exit quickly.npx claudepluginhub knight42/claude-plugins --plugin mygitBabysits GitHub PR until merge-ready by running pr-merge-prep every 10 minutes, monitoring CI status, reviews, and conflicts, then asks for explicit merge confirmation.
Drives existing GitHub/GitLab PRs/MRs to merge: monitors CI/CD status, fixes issues in PR scope via sub-skills, handles multi-round code reviews, resolves comments until all requirements met.
Monitors PR CI status, reads failure logs, applies targeted fixes, and optionally merges when all checks pass.