Index of every page on this site: llms.txt
All skills
bitwarden avatar

/code-review-local

@a11c77b official
by bitwardenbitwarden/ai-plugins165 stars
27
Run it yourself

Review a GitHub pull request or local changes and write the review to local files instead of posting

Use this Skill: https://skilld.dev/gh/bitwarden/ai-plugins/code-review-local

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

README.md

≈1.1k tokens on demand. Your agent reads this file only when SKILL.md points to it.

/code-review-local - Local Code Review Skill

Reviews a GitHub pull request or your local git changes with the bitwarden-code-reviewer agent and writes the review to local files instead of posting it. Use it to preview a review before it goes on a pull request, to review a branch that has no pull request yet, or to feed a review into your own tooling.

Usage

/code-review-local [PR# | PR URL | --base <ref>] [--output-dir <path>]
  • PR# or PR URL: the pull request to review, by number or full URL
  • --base <ref>: for local changes only, the ref the branch is diffed against instead of origin/HEAD. Use the remote-tracking form (origin/rc): a bare rc needs a local branch of that name, which can sit behind the remote. Dropped with a pull request target, where GitHub's recorded base is used. The ref must match ^[A-Za-z0-9][A-Za-z0-9._/-]*$
  • --output-dir <path>: directory for the review files. Defaults to ${CLAUDE_PLUGIN_DATA}/code-reviews/
  • No arguments: the command asks whether to review a pull request or the local changes

Only the space-separated forms are accepted. --base=rc, --output-dir=foo, or a flag with no value is refused before the review starts.

Examples

# A pull request, by number or URL
/code-review-local 123
/code-review-local https://github.com/bitwarden/mobile/pull/4567

# Local changes: choose "local changes" when asked
/code-review-local

# A branch cut from a release branch
/code-review-local --base origin/rc

# Somewhere other than the default directory
/code-review-local 123 --output-dir /tmp/reviews

For local changes the agent reviews one scope, not both: the branch against its base when it has commits ahead of that base, otherwise your pending changes (tracked edits plus untracked source files). To review uncommitted edits on a branch that is already ahead of its base, commit them first and re-run. The summary names the scope and the base it used. A --base ref that does not resolve produces a No Verdict rather than a review of some other scope.

Output files

The agent, not this command, decides where the files go and what they are called; the command only passes --output-dir through. The agent flow diagrams show the rule.

Target Files
Pull request code-review-local-PR-<n>-summary.md, code-review-local-PR-<n>-inline-comments.md
Local changes code-review-local-<branch>-<YYYY-MM-DD>-summary.md, code-review-local-<branch>-<YYYY-MM-DD>-inline-comments.md

Both land in ${CLAUDE_PLUGIN_DATA}/code-reviews/, or in --output-dir when given, and the command prints the full path of each. Writes under ~/.claude/ ask for approval, so headless runs (claude -p) need --output-dir set to an allowed directory.

Summary file. The summary comment, in the format posting-review-summary posts to GitHub:

## 🤖 Bitwarden Claude Code Review

**Overall Assessment:** APPROVE / REQUEST CHANGES

[Up to 4 neutral sentences describing what was reviewed]

<details>
<summary>Code Review Details</summary>

- ❌ : [One-line description]
  - `filename.ts:42`

</details>

When nothing could be reviewed it carries the NO VERDICT form instead, with the reason in place of the assessment sentences.

Inline-comments file. Every inline comment the agent would have posted, with file and line references. Empty when there are none.

## [file-path]:[line-number]

[Emoji] **[SEVERITY]**: [One-line description]

<details>
<summary>Details and fix</summary>

[Full details, code examples, rationale]

</details>

---

Posting a reviewed draft

/code-review-local 123 --output-dir /tmp/reviews
cat /tmp/reviews/code-review-local-PR-123-summary.md
gh pr comment 123 --body-file /tmp/reviews/code-review-local-PR-123-summary.md

Requirements

  • GitHub CLI (gh) installed and authenticated, for pull request targets
  • The bitwarden-code-review plugin installed

Related documentation

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

1 warning10d3 checks · Risk SAFE
  • Gen Agent Trust Hub10d

    This skill reviews GitHub pull requests or local git changes and writes the findings to local files. It implements robust input validation using regular expressions to mitigate command injection risks. It is categorized as low risk because it processes external data from pull requests, making it a surface for indirect prompt injection.

  • Socket10d

    No alerts

  • Snyk10d

    Risk: MEDIUM · 1 issue

Signed by skilld at a11c77b. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub yesterday.

Activeupdated 2 weeks ago
What it can do
Runs commands
All 2 allowed tools
AskUserQuestionTask
Other metadata
argument-hint
[PR# | PR URL | --base <ref>] [--output-dir <path>] | (blank to choose interactively)

README badge

README badge for bitwarden/ai-plugins/code-review-local