# Create Pull Request

> Analyze changes and create a pull request using the gh CLI with repo conventions.

- Skill: `majiayu000/create-pull-request-5` (Agent Skill, multi-file: 2 files)
- Install (CLI): `npx skillmds add majiayu000/create-pull-request-5`
- Raw SKILL.md: https://api.skillmd.com/api/skills/majiayu000/create-pull-request-5/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Integrations & APIs
- Author: majiayu000 (https://skillmd.com/u/majiayu000)
- Updated: 2026-09-09
- Page: https://skillmd.com/skills/majiayu000/create-pull-request-5

---


1. **Analyze changes**: Review all commits on the branch since it diverged from main:

   ```bash
   git log main..HEAD --oneline
   git diff main...HEAD
   ```

2. **Push the branch** if it has not been pushed yet:

   ```bash
   git push -u origin HEAD
   ```

3. **Create the PR** using the `gh` CLI with the required repo flags:

   ```bash
   gh pr create \
     -a @me \
     -r @carrot-foundation/developers \
     --label <label> \
     -R carrot-foundation/methodology-rules \
     -t "<type>(<scope>): <description>"
   ```

   - **Labels**: `feature`, `bug`, `chore`, `docs`, `refactoring`
   - **Title**: Use conventional commit format matching the branch type
   - **Body**: Include a summary section, details of what changed, and a declaration checkbox

4. **Return the PR URL** to the user once created.

