prereview

prereview is a skill for Claude Code, Codex from erraggy/oastools. It costs 54 tokens per session (1,136 once invoked), scanned A, original, MIT.

A pre-push review process for commits that have not yet been sent to a remote repository. It checks code quality, bugs, security, and error handling before those commits are pushed.

In plain words
What is it for?
Use it to review unpushed commits, handle any uncommitted changes first, and assess the changes before pushing them.
Why use it?
It can catch problems while changes are still local, when correcting them is easier and they have not yet entered a shared review flow.

Skill for Claude CodeCodex

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 skills/erraggy/oastools/prereview
Any agent
npx skills add erraggy/oastools --skill prereview
Clone the repo
git clone --depth 1 https://github.com/erraggy/oastools

Made for: Claude Code, Codex.

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 prereview

README.md
[![agentmods](https://agentmods.dev/badge/skills/erraggy/oastools/prereview.svg)](https://agentmods.dev/skills/erraggy/oastools/prereview)
Your own site
<a href="https://agentmods.dev/skills/erraggy/oastools/prereview"><img src="https://agentmods.dev/badge/skills/erraggy/oastools/prereview.svg" alt="Measured on agentmods" height="20"></a>
Per session 54 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,136 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.00054 $0.01136
Opus 5 $0.00027 $0.00568
Sonnet 5 $0.00011 $0.00227
Haiku 4.5 $0.00005 $0.00114

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

Security

Grade A, and why

prereview 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 5d 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.

.claude/skills/prereview/SKILL.md · 121 lines

How it starts

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

prereview

Review unpushed commits before pushing, using the same comprehensive analysis as PR reviews.

You are performing a pre-push code review. The user has commits ready to push but wants them reviewed first.

Step 0: Check for Uncommitted Changes

Before checking for unpushed commits, check if there are uncommitted changes that should be committed first:

# Check for staged or unstaged changes
git status --porcelain

If there are NO unpushed commits BUT there ARE uncommitted changes:

Use the AskUserQuestion tool to ask:

Question: "No unpushed commits found, but you have uncommitted changes. Would you like to commit them first?"

Options:

  1. Commit all changes - Stage all changes and create a commit (will prompt for message)
  2. Commit staged only - Commit just what's currently staged
  3. Cancel - Exit without reviewing

If the user chooses to commit:

  • For "Commit all changes": Run git add -A first
  • Use the Skill tool to invoke commit-commands:commit to create a proper conventional commit
  • After the commit succeeds, continue to Step 1

If there are NO unpushed commits AND NO uncommitted changes:

  • Inform the user: "Nothing to review - no unpushed commits and no uncommitted changes."
  • Exit the skill

Step 1: Identify Unpushed Changes

First, determine what needs to be reviewed:

# Get the current branch
git branch --show-current

# Check if there's an upstream tracking branch
git rev-parse --abbrev-ref @{upstream} 2>/dev/null || echo "NO_UPSTREAM"

# Show unpushed commits (if upstream exists)
git log @{upstream}..HEAD --oneline 2>/dev/null || git log origin/main..HEAD --oneline 2>/dev/null || git log origin/master..HEAD --oneline 2>/dev/null

Step 2: Get the Full Diff

Get the complete diff of all unpushed changes:

# Diff against upstream, falling back to origin/main or origin/master
git diff @{upstream}..HEAD 2>/dev/null || git diff origin/main..HEAD 2>/dev/null || git diff origin/master..HEAD 2>/dev/null

Read the full file on GitHub · 121 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. 5d ago First seen · 121 lines · 54 tokens per session scan A fababe35c22d

Subscribe to this mod's changes

prereview is a skill published in the GitHub repository erraggy/oastools (5 stars, last pushed 6d ago), licensed MIT. It adds 54 tokens to every session and 1,136 once invoked, about $0.0003 per session on Opus 5. 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.