pr-base-commit

Resolve the pre-merge commit SHA from a PR URL or number.

Updated Aug 27, 2026
One-click install
npx skills add https://github.com/MinhOmega/marlin-skill --skill pr-base-commit
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: pr-base-commit
Source: https://github.com/MinhOmega/marlin-skill/tree/main/.claude/skills/pr-base-commit
Command: npx skills add https://github.com/MinhOmega/marlin-skill --skill pr-base-commit

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Determine the pre-merge commit (the buggy state) for a merged PR so you can reproduce and test fixes.

Core Features & Use Cases

  • Identify the pre-merge commit for a PR to reproduce bugs.
  • Enable deterministic evaluation by checking out the buggy code state for testing and comparison.

Quick Start

Checkout to the pre-merge commit using the PR URL or number to reproduce the buggy state.

Frequently Asked Questions about pr-base-commit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I checkout the pre-merge commit of a merged PR to reproduce a bug?

To checkout the pre-merge commit for a merged PR, provide the PR URL or PR number to resolve the first PR commit's parent SHA. This deterministic checkout lets you reproduce the buggy state for testing and validation.

What is a pre-merge commit and when do I need it for bug reproduction?

A pre-merge commit represents the buggy state right before a PR is merged into the main branch. You need it to deterministically checkout and test the exact code state where a bug was originally reported.

Can I find the pre-merge state using only a PR number without the full GitHub URL?

Yes, you can find the pre-merge state using a PR number if you also provide a repository spec. This resolves the first PR commit's parent SHA to identify the pre-merge state across GitHub repositories.

Does identifying the pre-merge commit work across different GitHub repositories?

Yes, identifying the pre-merge commit works across GitHub repositories. It accepts a PR URL or PR number with an optional repository spec to resolve the parent SHA for any merged PR.

Why check out the parent SHA of the first commit instead of the PR's merge commit?

Checking out the parent SHA of the first PR commit captures the exact buggy state before any fixes were applied. This enables deterministic evaluation by testing the original code state rather than the final merge.