agentleFS
maroffomaroffo/claude-forge/skills/gemini-review/SKILL.md

gemini-review

Skill17 starsChanged 52 days agoMITView on GitHub

Local code review with Gemini CLI for pre-commit reviews. Use when user says review code, code review, check my changes, or review before commit.

  • Reads credentials

7 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use codex-review.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • juriwiensSkill

    codex-review

    Run code review via Codex CLI

    Also in 5 projects that use this

The file

We split this skill into the rules it gives an agent

3 rules. 0 are common, 2 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 6 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Every gemini call uses --model gemini-3.1-pro-preview, as in the commands below.

    line 13
  2. Distinctive:

    If no changes, inform user and suggest:

    line 46
  3. Distinctive:

    Read the diff yourself before sending it, so you can judge Gemini's findings against it

    line 93

“Common” is measured: kept by at least 6 in 10 of the 6 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

ABOUTME: Local code review skill using Gemini CLI for pre-commit reviews

ABOUTME: Supports staged, uncommitted, or branch diff with configurable prompts

Gemini Review - Local Code Review

Every gemini call uses --model gemini-3.1-pro-preview, as in the commands below; do not substitute or fall back to another model.

Options

OptionDescriptionDefault
--allReview all uncommitted changesstaged only
--branch [base]Review current branch vs basemain
--prompt <name>Use specific prompt templatedefault
--extensionUse Gemini's built-in /code-reviewcustom prompt

Execution Flow

Step 1: Determine diff scope

# Default: staged changes
git diff --cached

# With --all: all uncommitted
git diff HEAD

# With --branch [base]: branch vs base (default base: main)
git diff main...HEAD

Step 2: Check if there are changes to review

# Check if diff is empty
git diff --cached --quiet && echo "No staged changes" || echo "Has changes"

If no changes, inform user and suggest:

  • git add <files> to stage changes
  • --all flag for uncommitted changes
  • --branch flag for branch review

Step 3: Load prompt template

Prompt templates are in ~/.claude/skills/gemini-review/prompts/:

  • default.md - Concise review focused on bugs/security/performance
  • ci-style.md - Detailed review matching CI pipeline style

Step 4: Execute review

Option A - Using built-in extension (with --extension flag):

cd <project_root>
gemini --model gemini-3.1-pro-preview --yolo "/code-review"

Option B - Using custom prompt (default):

cd <project_root>

# Generate diff
DIFF=$(git diff --cached)

# Read prompt template
PROMPT=$(cat ~/.claude/skills/gemini-review/prompts/default.md)

# Invoke Gemini with prompt and diff
gemini --model gemini-3.1-pro-preview --yolo <<EOF
$PROMPT

## Code Changes to Review

\`\`\`diff
$DIFF
\`\`\`
EOF

Step 5: Present results

Gemini's output will appear in the terminal. Summarize key findings for the user.

Quality Notes

  • Read the diff yourself before sending it, so you can judge Gemini's findings against it
  • Summarize the findings instead of relaying raw output, and mark the false positives you spot

Important Notes

  1. Always run from project root - Gemini needs project context
  2. Check for CLAUDE.md/GEMINI.md - Include project guidelines in prompt if present
  3. Large diffs - For very large diffs (>10000 lines), suggest --branch with specific files
  4. Exit codes - Gemini CLI returns 0 on success, non-zero on error

Troubleshooting

IssueSolution
"No staged changes"Run git add <files> or use --all
"gemini: command not found"Install Gemini CLI: see https://github.com/google-gemini/gemini-cli
API errorsCheck GEMINI_API_KEY is set
Timeout on large diffsSplit into smaller reviews or use --extension

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.