Skip to content
Agentmart
Submit a tool

code-review

Code review agent for openstack-k8s-operators following dev-docs conventions, lib-common patterns, and openstack-k8s-operators best practices

Skill by openstack-k8s-operators

IndexedMIT★ 9
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/openstack-k8s-operators-code-review

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Code review agent for openstack-k8s-operators following dev-docs conventions, lib-common patterns, and openstack-k8s-operators best practices

Use cases: devops, agent-building

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/code-review

What's inside

Skill name
code-review
Description
Code review agent for openstack-k8s-operators following dev-docs conventions, lib-common patterns, and openstack-k8s-operators best practices
License
MIT
Instructions
191 lines in SKILL.md · view on GitHub

Agent Skills spec issues

  • allowed-tools: must be a space-separated string

Files (1)

  • SKILL.md

SKILL.md (first lines)

You are the openstack-k8s-operators code review skill. You determine the review scope, fetch the diff, and dispatch the `code-review` agent.

## Invocation

Determine the review scope from the argument:

1. **PR number**: `/code-review 123` or `/code-review PR#123` — uses `gh` CLI to fetch the PR from the **current repository**
2. **PR URL**: `/code-review https://github.com/openstack-k8s-operators/glance-operator/pull/123`
3. **Branch diff**: `/code-review` (no argument) — diff current branch against `main`
4. **Specific files**: `/code-review path/to/file.go`

## Fetching the Diff

### For PR reviews

When only a number is provided, the skill relies on `gh` CLI operating against the current git repository. Try `gh` first (read-only operations only):

```bash
# Get the diff (from the current repository)
gh pr diff <number>

# Get PR metadata (title, description, labels, reviewers)
gh pr view <number>

# Get changed file list
gh pr diff <number> --name-only

# Get PR comments and review threads
gh pr view <number> --comments
```

If `gh` is not available or fails (not authenticated, not installed):

1. Inform the user: "GitHub CLI not available. Fetching PR via web."
2. Derive `<owner>/<repo>` from the current git remote:

   ```bash
   git remote -v
   ```

   Pick the first remote that points to GitHub (prefer `origin` if it exists, otherwise use whatever is available). Parse the URL to extract the GitHub owner and repository name.
3. Fall back to WebFetch:
   - Fetch the raw diff: `https://github.com/<owner>/<repo>/pull/<number>.diff`
   - Fetch PR metadata: `https://github.com/<owner>/<repo>/pull/<number>`
4. If both fail, ask the user to provide the diff manually: "Could not fetch PR. Paste the diff or provide file paths to review."

### For branch diffs

```bash
git diff main...HEAD
git diff main...HEAD --name-only
```

### For specific files

Read the files directly with the Read tool.

## Dependency Resolution

Before dispatching the review agent, resolve dependencies that provide context for the review.

### Depends-On (PR description)

Check the PR description for `Depends-On:` lines. These reference PRs in other repos that this PR builds on:

```
Depends-On: https://github.com/openstack-k8s-operators/lib-common/pull/789
Depends-On: https://github.com/openstack-k8s-operators/openstack-operator/pull/456
```

For each dependency:

1. Fetch the dependent PR diff and description (via `gh` or WebFetch)
2. Understand what API changes, new helpers, or new types the dependency introduces
3. Use this knowledge when reviewing the current PR -- the PR under review may reference types, functions, or patterns that only exist in the dependent PR

### Replace directives (go.mod)

Check `go.mod` in the diff for `replace` directives pointing to private branches:

```go
replace github.com/openstack-k8s-operators/lib-common/modules/common => github.com/user/lib-common/modules/common v0.0.0-branch
```

These indicate the PR depends on unreleased changes in another repository. For each replace directive:

1. Identify the source repo and branch
2. Find the corresponding open PR:
   - Search via `gh pr list --repo <repo> --head <branch>` if `gh` is available
   - Or WebFetch `https://github.com/<owner>/<repo>/pulls?q=head:<branch>`
3. Fetch that PR's diff to understand what new code is being provided
4. The review should account for this -- e.g., if lib-common adds a new helper and the operator PR uses it, that usage is valid even though the helper doesn't exist in main yet

### Review with dependency context

When dependencies are found, include them in the agent prompt:

```
Dependencies resolved:
- lib-common PR #789: adds TopologyHelper to common/topology module
- openstack-operator PR #456: updates shared CRD types

The PR under review may use types/functions from these dependencies.
Do not flag usage of dependency-provided code as "missing" or "undefined".
```

## Workflow

1. Determine review scope (PR, branch diff, or specific files)
2. Fetch the diff and changed file list (gh → WebFetch → manual fallback)
3. For PRs: also fetch PR description and any existing review comments
4. **Resolve dependencies** (Depends-On from description + replace directives from go.mod)
5. **Dispatch the code-review agent**:

```
Agent(
  subagent_type="openstack-k8s-agent-tools:code-review:code-review",
  description="Review <scope>",
  prompt="<diff + changed files + PR metadata + dependency context>"

From openstack-k8s-operators/devskills, MIT.

More from openstack-k8s-operators/devskills

Signals

Stars
9
Forks
23
Open issues
0
Last commit (this folder)
Jun 4, 2026 (4 months ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from openstack-k8s-operators

Cite this page

code-review skill. Agent Mart. https://agentmart.dev/skills/openstack-k8s-operators-code-review (last updated 2026-10-24)