Fetches GitHub PR diffs and metadata, converting them into LLM-friendly markdown files.

Install

mkdir -p .claude/skills/pr-tonkeeper && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/17510" && unzip -o skill.zip -d .claude/skills/pr-tonkeeper && rm skill.zip

Installs to .claude/skills/pr-tonkeeper

Activation

This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.

toolkit for llm-friendly interaction with GitHub pull requests; using this skill the LLM can fetch PR data and analyze it
121 charsno explicit “when” trigger
Beginner

Key capabilities

  • Fetch GitHub PR metadata
  • Retrieve PR file diffs
  • Structure PR data into Markdown files
  • Write PR data to a specified output directory
  • Load .env files from the repository root
  • Fetch PRs from a specific repository

How it works

This skill uses a Python script to interact with the GitHub CLI, fetching PR metadata and file diffs. It then formats this data into Markdown files for easier analysis.

Inputs & outputs

You give it
python3 .codex/skills/pr/scripts/get_pr_data.py get-pr 354
You get back
Markdown files for diffs and a sha.json file in .context/tasks/354/

When to use pr

  • Automate PR code review
  • Analyze diff contents
  • Generate PR summaries
  • Fetch PR metadata

About this skill

Import pull request data as markdown

Use this skill to fetch PR metadata and file diffs into LLM-friendly Markdown files.

Prereqs

  • Ensure gh is installed and gh auth login has been completed.
  • Confirm setup: python3 .codex/skills/pr/scripts/get_pr_data.py ensure-setup returns zero exit code.

Usage

Fetch a PR by number:

python3 .codex/skills/pr/scripts/get_pr_data.py get-pr 354

Fetch from a specific repo:

python3 .codex/skills/pr/scripts/get_pr_data.py get-pr 354 --repo tonkeeper/ios_private

Write to a custom output directory:

python3 .codex/skills/pr/scripts/get_pr_data.py get-pr 354 --output /tmp/pr-354

Output

  • Default directory: .context/tasks/<PR_NUMBER>/ (relative to repo root)
  • One markdown file per diff (0.md, 1.md, ...) with keys as headings and the patch field in a diff code block.
  • sha.json with base commit metadata is written to the same directory.
  • .env is loaded from the repo root if present.

When not to use it

  • When `gh` is not installed or authenticated

Prerequisites

gh is installedgh auth login has been completed

Limitations

  • Requires `gh` CLI to be installed and authenticated
  • Output is structured into Markdown files with specific naming conventions

How it compares

This skill automates the process of extracting and structuring PR data into an LLM-friendly Markdown format, which is more efficient than manual data retrieval and formatting.

Compared to similar skills

pr side by side with the closest alternatives in the catalog.

SkillInstallsUpdatedSafetyDifficulty
pr (this skill)021dReviewBeginner
resolve-conflicts818moReviewIntermediate
dependency-upgrade264moReviewIntermediate
git-commits213moNo flagsBeginner

Try saying

Example prompts that trigger this skill in your AI assistant.

Search skills

Search the agent skills registry