rally-create-pr

rally-create-pr is a command for Claude Code from ddgonzal3/rally. It costs 0 tokens per session (771 once invoked), scanned A, original, MIT.

A command that prepares the current code changes for a pull request, a proposed change that teammates review before it is merged.

In plain words
What is it for?
Use it to inspect changes, create a feature branch when needed, push the work, and open a pull request.
Why use it?
It checks the branch and repository state first, reducing mistakes such as creating a duplicate pull request or pushing from the wrong branch.

Command for Claude Code

Written for Claude Code: a Claude Code command (commands/*.md).

Good fit Use it to inspect changes, create a feature branch when needed, push the work, and open a pull request.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/ddgonzal3/rally/rally-create-pr
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.

Clone the repo
git clone --depth 1 https://github.com/ddgonzal3/rally

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for rally-create-pr

README.md
[![agentmods](https://agentmods.dev/badge/commands/ddgonzal3/rally/rally-create-pr.svg)](https://agentmods.dev/commands/ddgonzal3/rally/rally-create-pr)
Your own site
<a href="https://agentmods.dev/commands/ddgonzal3/rally/rally-create-pr"><img src="https://agentmods.dev/badge/commands/ddgonzal3/rally/rally-create-pr.svg" alt="Measured on agentmods" height="20"></a>
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 771 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00000 $0.00771
Opus 5 $0.00000 $0.00385
Sonnet 5 $0.00000 $0.00154
Haiku 4.5 $0.00000 $0.00077

Measured 8d ago against content hash d1a35f16fb34, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

rally-create-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 8d 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.

src-tauri/resources/commands/rally-create-pr.md · 104 lines

How it starts

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

Create PR: Branch (if needed), Push, and Open PR

You are creating a pull request for the current working changes. Follow each step exactly.

Step 1: Detect State

BRANCH=$(git symbolic-ref --short HEAD)
MAIN_BRANCH=$(git symbolic-ref refs/remotes/origin/HEAD 2>/dev/null | sed 's@^refs/remotes/origin/@@')
[ -z "$MAIN_BRANCH" ] && MAIN_BRANCH="main"
IS_DIRTY=$([ -n "$(git status --porcelain)" ] && echo "true" || echo "false")
EXISTING_PR=$(gh pr view --json number,state -q 'select(.state=="OPEN") | .number' 2>/dev/null)
echo "BRANCH=$BRANCH MAIN=$MAIN_BRANCH DIRTY=$IS_DIRTY EXISTING_PR=$EXISTING_PR"

Guard rail: If EXISTING_PR is not empty, STOP: "PR #$EXISTING_PR already exists for this branch. Push new commits to update it, or use /review-pr to review it."

Step 2: Create Feature Branch (if on main)

If BRANCH equals MAIN_BRANCH:

  1. Inspect the working tree to understand the changes:
    git diff --stat
    git diff --cached --stat
    git status --porcelain
    
  2. Generate a short, descriptive kebab-case branch name based on the changes (e.g., add-user-auth, fix-sidebar-layout, update-ship-command). If there are no changes to inspect, use the surrounding conversation context.
  3. Create and switch to the branch:
    git checkout -b <generated-branch-name>
    
  4. Update: BRANCH=<generated-branch-name>

Step 3: Commit if Dirty

Only if IS_DIRTY=true:

  1. Read the diff to understand what changed:

    git diff --stat
    git diff --cached --stat
    
  2. Write a concise, descriptive commit message based on the diff:

    git add -A
    git commit -m "<your descriptive message>"
    

If the working tree is clean and there are no new commits beyond main, STOP: "Nothing to create a PR for — no changes found."

Step 4: Push

git push 2>/dev/null || git push --set-upstream origin "$BRANCH"

Step 5: Analyze Changes and Create PR

Read the full diff against main to write a good PR description:

Read the full file on GitHub · 104 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. 8d ago First seen · 104 lines · 0 tokens per session scan A d1a35f16fb34

Subscribe to this mod's changes

rally-create-pr is a command published in the GitHub repository ddgonzal3/rally (6 stars, last pushed 1mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 771 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.