pr

A command for creating or updating a GitHub pull request, which proposes code changes for review and merging.

In plain words
What is it for?
Use it to open or update a pull request from the current branch, push commits, connect related issues, and assign yourself.
Why use it?
It applies repository rules for branches, Korean-language content, labels, accounts, and existing pull requests.

Command for Cursor

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/ohah/react-native-mcp/pr
Clone the repo
git clone --depth 1 https://github.com/ohah/react-native-mcp

Made for: Cursor.

Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 949 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00949
Opus 5 $0.00000 $0.00475
Sonnet 5 $0.00000 $0.00190
Haiku 4.5 $0.00000 $0.00095

Measured 2d ago against content hash 2e327012073b, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

pr scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/commands/pr.md · 61 lines

How it starts

The opening of the file, as written. The whole thing — 61 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Pull Request 생성 또는 업데이트

현재 브랜치 기준으로 PR 생성·업데이트. AGENTS.MD의 PR 규칙을 따른다.

언어

PR 제목, 본문, branch-summary.md 모두 한국어로 작성한다.

에이전트가 할 일

  1. 브랜치·PR 상태: git branch --show-current, gh pr list --head <현재브랜치> --state all
  2. 이미 열린 PR이 있으면: 새 브랜치·새 PR 만들지 않음. 현재 브랜치에 커밋 추가 후 push.
  3. base: 사용자가 지정하면 그 브랜치를 머지 대상으로 사용.
    • 현재 브랜치와 base가 같으면: 현재 브랜치에서 새 브랜치를 만들어 PR head로 사용.
  4. 본문: branch-summary.md가 있으면 PR 본문으로 사용. 한국어로 작성.
  5. 이슈 연결: gh issue list --state open --limit 50 실행. 관련 이슈 있으면 본문에 Relates to #<번호> 또는 Fixes #<번호> 추가.
  6. PR 생성·업데이트:
    • 열린 PR 없음 → gh pr create --head <현재브랜치> --base <base> --title "<제목>" --body-file branch-summary.md --assignee @me
    • 열린 PR 있음 → REST API로 제목·본문만 수정 (아래 "구형 API 사용 금지" 참고).
  7. Push: 푸시 안 된 커밋 있으면 git push origin <현재브랜치>.
  8. 담당자: PR 생성 시 항상 --assignee @me.
  9. 라벨: gh label list 확인 후 PR 타입에 맞는 라벨 추가 (feat → enhancement, fix → bug, docs → documentation 등).

gh 계정·SSH (이 레포)

  • origin: git remote set-url origin [email protected]:ohah/react-native-mcp.git
  • gh: push·gh pr creategh api user -q .login으로 사용자 확인. ohah 아니면 gh auth switch --hostname github.com --user ohah 후 작업. 작업 끝나면 이전 사용자로 복원.

PR 제목 규칙

  • 사용자가 제목 지정 → 그대로 사용.
  • 이슈 참조 (예: /pr fixes #123) → [#123] 접두사 + 짧은 주제.
  • 둘 다 없음 → 한국어로 짧고 명령형 주제.

PR 본문 형식

branch-summary.md를 본문으로 사용. 포함 내용:

  • 제목(목적): 이 PR의 목적
  • 작업 내용: 무엇을·왜 변경했는지 산문체로 작성

구형 API 사용 금지

  • gh pr edit로 PR 제목/본문을 수정하지 말 것.
    gh pr edit는 내부적으로 deprecated된 GraphQL 필드(Projects classic, repository.pullRequest.projectCards)를 사용해, 제목/본문만 바꾸는 경우에도 deprecation 경고가 나오고 exit code 1로 실패할 수 있음.
  • PR 제목·본문 수정 시: REST API를 사용한다. 본문은 파일 내용을 JSON으로 넣어야 하므로 jq로 payload 생성 후 --input -로 전달한다.
    REPO=$(gh repo view --json nameWithOwner -q .nameWithOwner)
    jq -n --rawfile b branch-summary.md --arg t "제목" '{title: $t, body: $b}' | \
      gh api -X PATCH "repos/${REPO}/pulls/PR번호" --input -
    
  • 라벨 추가: gh pr edit --add-label 대신 REST API. JSON 배열은 --input -로 전달한다.
    echo '{"labels":["enhancement"]}' | gh api -X POST "repos/${REPO}/issues/PR번호/labels" --input -
    

Read the full file on GitHub · 61 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 61 lines · 0 tokens per session scan A 2e327012073b

Subscribe to this mod's changes

pr is a command published in the GitHub repository ohah/react-native-mcp (7 stars, last pushed 5mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 949 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.