update-pr-description

Rewrite pull request titles and bodies to match the current diff.

Updated Dec 21, 2018
One-click install
npx skills add https://github.com/dhnt/dhnt --skill update-pr-description-dhnt
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: update-pr-description
Source: https://github.com/dhnt/dhnt/tree/main/catalog/md/integrate/update-pr-description
Command: npx skills add https://github.com/dhnt/dhnt --skill update-pr-description-dhnt

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It solves the problem of PR descriptions becoming outdated after review work changes what’s actually in the diff, causing reviewers to start from incorrect assumptions.

Core Features & Use Cases

  • Detect description drift: Compares the current PR title and body against the full diff from the base branch to surface mismatches.
  • Rewrite for clarity: Updates content by replacing incorrect or stale bullets while preserving the PR’s overall section structure.
  • Refresh the test plan and scope: Ensures the test-plan and stated scope reflect what was truly added, removed, deferred, or newly introduced.
  • Use safe update mechanics: Applies updates through the platform API and posts a concise reply indicating what changed.

Quick Start

Use update-pr-description to rewrite the PR title and body so they match the latest diff against the base branch.

Frequently Asked Questions about update-pr-description

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

FAQPage Schema
How do I update a pull request description to match the current diff?

To update a pull request description, you can analyze the full diff against the base branch, rewrite mismatched sections without appending, and apply the updated title and body via the platform API.

Why does my GitHub PR description drift from the actual branch changes during code review?

PR description drift occurs because review work changes what is actually in the diff after the PR was opened. This causes the original title, scope, and test plan text to become misleading and outdated.

What is the best way to refresh a stale PR test plan after scope updates?

The best way to refresh a stale PR test plan is to compare the current body against the full diff, replace incorrect bullets while preserving the section structure, and update the description via the platform API.

How do I rewrite a pull request title and body without appending duplicate content?

You rewrite a pull request title and body by reading the current description, analyzing the full diff, and replacing mismatched sections directly rather than appending new text, ensuring the output reflects the true scope.

Does updating a PR description via the API cause formatting or quoting issues?

Updating a PR description via the API can cause quoting issues, which is why using a heredoc is recommended to safely pass the rewritten title and body text without formatting errors.

When do I need to update my PR description during code review?

You need to update your PR description when review phase changes alter the scope, behavior, or test-plan coverage, making the original text inaccurate for reviewers starting their analysis.