oxghmerge-or-fix

star 11

Wait for AI code review on a PR — auto-merge if clean, fix issues if not

oxidian By oxidian schedule Updated 3/3/2026

name: oxgh:merge-or-fix description: Wait for AI code review on a PR — auto-merge if clean, fix issues if not

Context

First, run these commands and review their output:

  • Git remote: git remote get-url origin

Your Task

  1. Get PR number: Use $ARGUMENTS if provided, otherwise detect from current branch with gh pr view --json number --jq '.number'
  2. Checkout PR branch: Run gh pr checkout <PR_NUMBER> to ensure you're on the PR's branch (safe to run even if already on the branch)
  3. Wait for AI review: Run python3 scripts/wait_for_ai_review.py <PR_NUMBER> (use 45 minute timeout)
  4. Read all PR comments: Parse the owner/repo from the git remote above, then run gh api repos/{owner}/{repo}/issues/<PR_NUMBER>/comments
  5. Analyze and respond:
    • If there are findings: identify the highest priority review comment only. Investigate the codebase to understand that specific issue, then immediately create an implementation plan to fix it using TDD. Do NOT ask the user whether they want to fix the issue - assume they do. Write the full plan directly. Ignore lower priority comments for now.
    • If no findings: auto-merge by running exactly gh pr merge --auto (no other flags)
Install via CLI
npx skills add https://github.com/oxidian/cc-plugins --skill oxghmerge-or-fix
Repository Details
star Stars 11
call_split Forks 0
navigation Branch main
article Path SKILL.md
More from Creator