Skip to content

espennilsen/pi / skills/github

github

Verified

Interact with GitHub repos, PRs, issues, CI, and notifications via the pi-github extension commands and gh CLI. Use when asked to check PRs, list issues, view repo status, check CI, browse notifications, create or merge PRs, fix PR review feedback, or perform any GitHub operation. **Triggers:** "open PRs", "repo status", "CI status", "merge PR", "fix PR", "fix PRs", "fix review feedback", "create PR", "GitHub notifications", any /gh-* command, or when a GitHub PR URL is shared.

FileKindSize
SKILL.mdskill md4.0 KB
references/pr-create.mdmarkdown1.2 KB
references/pr-fix-parallel.mdmarkdown7.8 KB
references/pr-fix.mdmarkdown4.8 KB
references/pr-merge.mdmarkdown2.9 KB
scripts/check-conflicts.shexecutablescript997 B
scripts/fetch-threads.shexecutablescript2.7 KB
scripts/reply-thread.shexecutablescript1.1 KB
scripts/resolve-thread.shexecutablescript1.2 KB

scripts/reply-thread.sh

View on GitHub
#!/usr/bin/env bash
# Reply to a PR review thread.
#
# Usage: bash scripts/reply-thread.sh <thread-id> <reply-body>
#
# Example:
#   bash scripts/reply-thread.sh PRRT_kwDOROE4Hs50bONT "Fixed — added null guard"
#
# Idempotency: This script is NOT idempotent — re-running will post a
# duplicate reply. Callers that need retry logic should check for an
# existing reply (e.g. via fetch-threads.sh) before invoking.
set -euo pipefail

thread_id="${1:?Usage: reply-thread.sh <thread-id> <reply-body>}"
reply_body="${2:?Usage: reply-thread.sh <thread-id> <reply-body>}"

echo "→ Replying to thread ${thread_id}..."
result=$(gh api graphql \
  -f query='
    mutation($threadId: ID!, $body: String!) {
      addPullRequestReviewThreadReply(input: {
        pullRequestReviewThreadId: $threadId,
        body: $body
      }) { comment { id } }
    }' \
  -f threadId="$thread_id" \
  -f body="$reply_body")

if echo "$result" | jq -e '.errors' > /dev/null 2>&1; then
  echo "❌ Failed to reply to thread ${thread_id}." >&2
  echo "$result" >&2
  exit 1
fi

echo "✅ Replied to thread ${thread_id}."
receiving-code-reviewobra/superpowersUse when receiving code review feedback, before implementing suggestions, especially if feedback seems unclear or technically questionable - requires technical rigor and verification, not performative agreement or blind implementationStars: 319kUpdated Claude CodeCodexVerifiedInstall
requesting-code-reviewobra/superpowersUse when completing tasks, implementing major features, or before merging to verify work meets requirementsStars: 319kUpdated Claude CodeCodexVerifiedInstall
using-git-worktreesobra/superpowersUse when starting feature work that needs isolation from current workspace or before executing implementation plans - ensures an isolated workspace exists via native tools or git worktree fallbackStars: 319kUpdated Claude CodeCodexVerifiedInstall
verification-before-completionobra/superpowersUse when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions alwaysStars: 319kUpdated Claude CodeCodexVerifiedInstall