Skip to content
Back to skills

2830 Gemini Invocation 2d2b6edc

ASecurity

- Model: `gemini-3-pro-preview` - Extensions: `code-review`, `gemini-cli-security`

  • 9 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added October 11, 2026
code-qualitygoshellbashcode-reviewgitsecurityperformance

Works with

  • cli

Security analysis

A92/100
  • mediumInstalls packages at runtime which could introduce malicious dependencies

Pro shows the line behind each finding and how to fix it

Scanned October 11, 2026

npx -y skills add tools-only/X-Skills --skill 2830-gemini-invocation_2d2b6edc --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of 2830 Gemini Invocation 2d2b6edc?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for 2830 Gemini Invocation 2d2b6edc
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/tools-only-2830-gemini-invocation-2d2b6edc/badge)](https://www.skillsdirectory.com/skills/tools-only-2830-gemini-invocation-2d2b6edc)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

SKILL.md
# Gemini CLI Invocation

## Default Configuration

- Model: `gemini-3-pro-preview`
- Extensions: `code-review`, `gemini-cli-security`

## Key Flags

| Flag | Purpose |
|------|---------|
| `-p <prompt>` | Non-interactive (headless) mode |
| `--yolo` / `-y` | Auto-approve all tool calls |
| `-m <model>` | Model selection |
| `-e <ext>` | Load specific extension(s) |

## Scope-to-Diff Mapping

Gemini does not have built-in scope flags like Codex. Map the
user's scope choice to the correct `git diff` command:

| Scope | Diff command |
|-------|-------------|
| Uncommitted | `git diff HEAD` (captures both staged and unstaged) |
| Branch diff | `git diff <branch>...HEAD` |
| Specific commit | `git diff <sha>~1..<sha>` |

**Important:** For uncommitted scope, use `git diff HEAD` not
bare `git diff`. Bare `git diff` misses staged changes.

## Code Review (General, Performance, Error Handling)

For uncommitted changes, the `/code-review` extension
automatically picks up the working tree diff:

```bash
gemini -p "/code-review" \
  --yolo \
  -e code-review \
  -m gemini-3-pro-preview
```

For branch diffs or specific commits, pipe the diff with a
prompt header (avoids heredocs — diffs contain `$` and backticks
that break shell expansion):

```bash
git diff <branch>...HEAD > /tmp/review-diff.txt
{ printf '%s\n\n' 'Review this diff for code quality issues. <focus prompt>'; \
  cat /tmp/review-diff.txt; } \
  | gemini -p - -m gemini-3-pro-preview --yolo
```

## Security Review

The `/security:analyze` extension is interactive-only, so use
headless mode with a security-focused prompt instead:

```bash
git diff HEAD > /tmp/review-diff.txt
{ printf '%s\n\n' 'Analyze this diff for security vulnerabilities, including injection, auth bypass, data exposure, and input validation issues. Report each finding with severity, location, and remediation.'; \
  cat /tmp/review-diff.txt; } \
  | gemini -p - -e gemini-cli-security -m gemini-3-pro-preview --yolo
```

When security focus is selected, also run dependency scanning:

```bash
gemini -p "/security:scan-deps" \
  --yolo \
  -e gemini-cli-security \
  -m gemini-3-pro-preview
```

## Adding Project Context

If project context was requested, prepend it to the prompt:

```bash
git diff HEAD > /tmp/review-diff.txt
{ printf 'Project conventions:\n---\n'; \
  cat CLAUDE.md; \
  printf '\n---\n\n%s\n\n' '<review instructions and focus>'; \
  cat /tmp/review-diff.txt; } \
  | gemini -p - -m gemini-3-pro-preview --yolo
```

## Error Handling

| Error | Action |
|-------|--------|
| `gemini: command not found` | Tell user: `npm i -g @google/gemini-cli` |
| Extension missing | Tell user: `gemini extensions install <github-url>` |
| `-e security` silently ignored | Use `-e gemini-cli-security` (the actual installed name) |
| Timeout | Inform user, suggest scoping down the diff |

## Extension Install Commands

```bash
gemini extensions install https://github.com/gemini-cli-extensions/code-review
gemini extensions install https://github.com/gemini-cli-extensions/security
```

Note: The security extension installs as `gemini-cli-security`
(not `security`). Always use `-e gemini-cli-security` when
loading it.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.