Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

open-pull-request

БесплатноБез исполняемых скриптовНе проверен

Open a pull request from a feature branch with the GitHub CLI: fork base and head, title and body conventions, checks after. Use when asked to open a PR or…

torrustот torrust★ 539 звёзд на GitHub

Об этом скилле

Open a Pull Request

CLI vs MCP Decision Rule

  • Inner loop (fast local branch work): prefer GitHub CLI (gh pr create).
  • Outer loop (cross-system coordination): use MCP tools for structured/authenticated access.

Pre-flight Checks

Before opening a PR:

  • Working tree is clean: git status --short has no output. Do not open a PR while any tracked or untracked change is present. Commit the intended changes, or deliberately discard/stash unrelated changes first.
  • Upstream target repository confirmed from workspace metadata (Cargo.toml → repository)
  • Branch is based on a recent upstream develop (<upstream-remote>/develop): run git fetch <upstream-remote>, then check git log --oneline HEAD..<upstream-remote>/develop. Rebasing before opening the PR is recommended and is required when the branch conflicts with develop (see Keeping the branch up to date).
  • Branch is pushed to your fork remote
  • Commits are GPG signed (git log --show-signature -n 1)
  • All pre-commit checks passed (linter all, cargo machete, tests)
  • PR body claims are aligned with the actual commit range (<upstream-remote>/develop..HEAD)
  • If manual verification used temporary local-only patches, PR body explicitly says they are not included
  • PR body paragraphs are written as single continuous lines (no hard line wrapping)

Required pre-flight order

Run these checks immediately before gh pr create or an equivalent MCP creation request:

git status --short
git fetch <upstream-remote>
git log --oneline HEAD..<upstream-remote>/develop

Stop if the first command prints any path: restore a clean working tree first, so no uncommitted changes are accidentally omitted from, or confused with, the proposed commit range. If the final command prints commits, rebase on the fetched upstream develop before creating the PR unless that would be a bottleneck; the rebase is required when the branch conflicts with develop. A clean working tree is required both before rebasing and before opening the PR.

Keeping the branch up to date

Rebasing onto the latest upstream develop is recommended, not required, as recorded in the ADR to stop requiring pull-request rebases. A rebase detects integration problems before merge; the requirement was dropped only to reduce CI CPU consumption and runner costs. Rebase:

  • when opening a PR;
  • when you know develop has changed since your last push; and
  • in general, whenever you can and it is not a bottleneck or a problem.

Skip a recommended rebase that would be a bottleneck or a problem, for example when a queue of open PRs would rerun expensive CI after every merge, or when an in-progress review round cites the current commit ids. A rebase or other update is required only when:

  1. the branch conflicts with develop;
  2. it needs a change that landed on develop later, or a reviewer asks for the combination to be tested before merge; or
  3. the maintainer merge tool refuses it because GitHub's recorded base is stale and its own refresh is unavailable (see the merge-pull-request skill).
# Identify the upstream remote (commonly "torrust"; verify with git remote -v)
UPSTREAM_REMOTE=torrust  # replace if your remote has a different name

git fetch $UPSTREAM_REMOTE
git rebase $UPSTREAM_REMOTE/develop

# Then push (use --force-with-lease when rewriting history)
git push --force-with-lease <fork-remote> <branch-name>

Because a rebase rewrites the branch's commit ids and rebases still happen, no durable reference may cite a PR-branch commit by id. Durable references are repository artifacts (issue specs, evidence files, review audits), the PR body, which the maintainer merge tool copies into the merge commit, and review replies, which stay on GitHub after the branch is rewritten. Cite the Conventional Commit subject instead; ids are durable only once on develop. The rule holds whether or not the branch is ever rebased: an id cited during a normal review round becomes wrong at the next rebase. Run this check from the repository root before every push that changes an issue spec, evidence file, or review audit, and before pushing after a rebase:

UPSTREAM_REMOTE=torrust  # replace if your remote has a different name

git diff -z --name-only --diff-filter=d "$UPSTREAM_REMOTE/develop"...HEAD |
  xargs -0 -r grep -IohE '\b[0-9a-f]{7,40}\b' | sort -u |
  while read -r token; do
    git rev-parse -q --verify "$token^{commit}" >/dev/null || continue
    git merge-base --is-ancestor "$token" "$UPSTREAM_REMOTE/develop" ||
      echo "PR-branch commit id: $token"
  done

Empty output means no file the branch changes cites a commit that is not on develop. The check scans every changed text file, not only the issue folder, so it also covers review audits and evidence files. It keeps al

Полный SKILL.md на GitHub

Установить open-pull-request в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

FAQ

Что делает скилл open-pull-request?

Open a pull request from a feature branch with the GitHub CLI: fork base and head, title and body conventions, checks after. Use when asked to open a PR or submit a branch for review.

Как установить скилл open-pull-request?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл open-pull-request запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить open-pull-request с