Create pr

From tsinghua-fib-lab/AutoSOTA · View interactive version

Create pr is an AI agent skill from the GitHub repository tsinghua-fib-lab/AutoSOTA. Rebase the current branch onto the latest base branch, squash local commits, generate a Conventional Commit message, and create or update the GitHub pull request.

How to use this skill

Skill file

Create Pull Request

Use this skill when the user asks to create or update a PR for the current branch.

Inputs

Preconditions

  1. Verify the current branch is not main or master.
  2. Check for uncommitted changes with git status --short.
  3. Ensure gh is available.
  4. If there are uncommitted changes, stop and ask the user whether to commit or stash

them first.

Workflow

Step 1: Check for an existing PR

Step 2: Fetch and rebase

git fetch origin <base>
git rebase origin/<base>

Step 3: Squash into one commit

git reset --soft origin/<base>

Step 4: Generate PR title and body

reasons.

Step 5: Push and create or update the PR

Guardrails

Output

Report:

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.