# Github PR Description

Generate and create pull request descriptions automatically using GitHub CLI.

- Repository: https://github.com/tailcallhq/forgecode (7636 stars)
- Category: Testing
- License: Apache-2.0
- Last updated: 2026-11-01
- Runs scripts: no, instructions only

## Install

Claude Code: `npx skills add tailcallhq/forgecode --skill github-pr-description -g -a claude-code -y`
Codex: `npx skills add tailcallhq/forgecode --skill github-pr-description -g -a codex -y`
Cursor: `npx skills add tailcallhq/forgecode --skill github-pr-description -g -a cursor -y`
Gemini CLI: `npx skills add tailcallhq/forgecode --skill github-pr-description -g -a gemini-cli -y`

## Description

Generate and create pull request descriptions automatically using GitHub CLI. Use when the user asks to create a PR, generate a PR description, make a pull request, or submit changes for review. Analyzes git diff and commit history to create comprehensive, meaningful PR descriptions that explain what changed, why it matters, and how to test it.

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# Create PR Description

Generate comprehensive pull request descriptions and create PRs using GitHub CLI.

## Workflow

### 1. Verify Prerequisites

Check that there are changes to create a PR for:

```bash
# Get current branch
git branch --show-current

# Verify branch is not main/master
# Verify there are commits ahead of main
git log origin/main..HEAD --oneline
```

If on main/master or no commits ahead, inform the user there's nothing to create a PR for.

### 2. Analyze Changes

Gather context about the changes:

```bash
# Get commit messages
git log origin/main..HEAD --pretty=format:"%s"

# Get diff summary (files changed)
git diff origin/main..HEAD --stat

# Get actual code changes (sample key files if diff is large)
git diff origin/main..HEAD
```

**For large diffs**: Focus on the most meaningful changes. Sample key files rather than reading everything.

### 3. Determine Change Type

Classify the PR into one of these categories:

- **fix**: Bug fixes, error corrections, resolving issues
- **feature**: New functionality, capabilities, or enhancements
- **performance**: Speed improvements, optimization, efficiency gains
- **refactor**: Code restructuring without changing behavior
- **docs**: Documentation changes
- **test**: Test additions or improvements
- **chore**: Maintenance tasks, dependencies, configuration

Base this on:
- Commit messages (keywords like "fix", "add", "optimize", "refactor")
- Nature of code changes (new files = feature, test fixes = fix, etc.)
- Scope of changes

### 4. Generate Description

Create a comprehensive description with this structure:

```markdown
## Summary
[One sentence explaining what this PR does and why it matters]

## Context
[Background information, related issues, previous work, or the problem being solved]

## Changes
[High-level description of what changed]

### Key Implementation Details
[Technical details that help reviewers understand the approach, especially for complex changes]

The rest: https://github.com/tailcallhq/forgecode/blob/HEAD/crates/forge_repo/src/skills/github-pr-description/SKILL.md
