Token导航 LogoToken导航TokenDH.com
研究检索需要联网github未标认证来源可访问许可证需确认审计提醒

create-pr创建公关

Agent Skill

create-pr 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

353

周安装

15

GitHub Stars

公开资料未说明

下载量

124
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:create-pr(创建公关)
来源仓库:https://github.com/cartridge-gg/agents
仓库路径:skills/create-pr
安装命令:
npx skills add https://github.com/cartridge-gg/agents --skill create-pr
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/cartridge-gg/agents --skill create-pr

简介

create-pr 自动化创建 GitHub Pull Request,包含完整变更摘要与测试覆盖说明。

  • 适用于代码合入前的标准化提交流程,确保标题、描述与分支管理规范统一。
  • 自动关联 issue、检查 CI 状态并生成对比视图链接,提升协作透明度。
  • 使用前应确保 gh CLI 已认证且当前分支有明确 upstream 指向与合入目标。
  • create-pr 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

SKILL.md

The user likes the state of the code.

There are $git status --porcelain | wc -l | tr -d ' ' uncommitted changes. The current branch is $git branch --show-current. The target branch is origin/main.

$git rev-parse --abbrev-ref @{upstream} 2>/dev/null && echo "Upstream branch exists." || echo "There is no upstream branch yet."

Existing PR: $gh pr view --json number,title,url --jq '"#\(.number): \(.title) - \(.url)"' 2>/dev/null || echo "None"

The user requested a PR.

Follow these exact steps:

Phase 1: Review the code

  1. Review test coverage
  2. Check for silent failures
  3. Verify code comments are accurate
  4. Review any new types
  5. General code review

Phase 2: Create/Update PR

  1. Run git diff to review uncommitted changes
  2. Commit them. Follow any instructions the user gave you about writing commit messages.
  3. Push to origin.
  4. Use git diff origin/main... to review the full PR diff
  5. Check if a PR already exists for this branch:
  • If PR exists:

- Draft/update the description in a temp file (e.g. /tmp/pr-body.txt). - Update the PR body using the non-deprecated script: - ./.agents/skills/create-pr/scripts/pr-body-update.sh --file /tmp/pr-body.txt - Re-fetch the body with gh pr view --json body --jq.body to confirm it changed.

  • If no PR exists: Use gh pr create --base main to create a new PR. Keep the title under 80 characters and the description under five sentences.

The PR description should summarize ALL commits in the PR, not just the latest changes.

Phase 3: Monitor CI and Address Issues

Note: Keep commands CI-safe and avoid interactive gh prompts. Ensure GH_TOKEN or GITHUB_TOKEN is set in CI.

  1. Watch CI status and feedback using the polling script (instead of running gh in a loop):
  • Run ./.agents/skills/create-pr/scripts/poll-pr.sh --triage-on-change --exit-when-green (polls every 30s for 10 mins).
  • If checks fail, use gh pr checks or gh run list to find the failing run id, then:

- Fetch the failed check logs using gh run view <run-id> --log-failed - Analyze the failure and fix the issue - Commit and push the fix - Continue polling until all checks pass

  1. Check for merge conflicts:
  • Run git fetch origin main && git merge origin/main
  • If conflicts exist, resolve them sensibly
  • Commit the merge resolution and push
  1. Use the polling script output to notice new reviews and comments (avoid direct polling via gh):
  • If you need a full snapshot, run ./.agents/skills/create-pr/scripts/triage-pr.sh once.
  • If you need full context after the script reports a new item, fetch details once with gh pr view --comments or gh api....
  • Address feedback:

- For bot reviews, read the review body and any inline comments carefully - Address comments that are clearly actionable (bug fixes, typos, simple improvements) - Skip comments that require design decisions or user input - For addressed feedback, commit fixes with a message referencing the review/comment

Phase 4: Merge and Cleanup

  1. Once CI passes and the PR is approved, ask the user if they want to merge the PR.
  2. If the user confirms, merge the PR:

- Use gh pr merge --squash --delete-branch to squash-merge and delete the remote branch

  1. After successful merge, check if we're in a git worktree:

- Run: ["$(git rev-parse --git-common-dir)"!= "$(git rev-parse --git-dir)"] - If in a worktree: Use the ask user question tool (request_user_input) to ask if they want to clean up the worktree. If yes, run wt remove --yes --force to remove the worktree and local branch, then switch back to the main worktree. - If not in a worktree: Just switch back to main with git checkout main && git pull

Completion

Report the final PR status to the user, including:

  • PR URL
  • CI status (passed/merged)
  • Any unresolved review comments that need user attention
  • Cleanup status (worktree removed or branch switched)

If any step fails in a way you cannot resolve, ask the user for help.

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

33.96%
按下载量换算42

Claude

32.07%
按下载量换算40

Cursor

17.32%
按下载量换算21

Gemini CLI

9.27%
按下载量换算11

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

可疑

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills