You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .claude-plugin/plugin.json
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
{
2
2
"name": "rhdh",
3
3
"description": "All-in-one toolkit for Red Hat Developer Hub (RHDH). Covers plugin development, overlay management, environment setup, version compatibility, CI/CD, and RHDH ecosystem navigation.",
Copy file name to clipboardExpand all lines: README.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -61,7 +61,7 @@ Track work across the four RHDH Jira projects.
61
61
62
62
### PR Review
63
63
64
-
-**[rhdh-pr-review](./skills/rhdh-pr-review/SKILL.md)** — Test PR changes on a live RHDH cluster. Swaps CI images, verifies code changes, and reports findings.
64
+
-**[rhdh-pr-review](./skills/rhdh-pr-review/SKILL.md)** — PR code review with inline comments (GitHub, GitLab planned) and live cluster testing for rhdh-operator PRs. Layered architecture: fetch → analyze → post.
description: Test PR changes on a live RHDH cluster. Fetches CI-built images from PR comments, checks cluster status (deploying if needed), deploys the full PR operator bundle or manifests (not just image swap), actively verifies the code changes by exercising affected code paths on the cluster, and closes with findings including best-practice and security assessment. Use when asked to review an rhdh-operator PR, test PR changes on a cluster, deploy PR images for testing, or deploy PR bundle. Also use when user mentions "operator PR", "review PR", or "test this PR on my cluster". Currently supports rhdh-operator PRs.
3
+
description: >
4
+
Review pull requests: code-level analysis with inline comments, and live cluster testing for rhdh-operator PRs. Supports GitHub (GitLab planned). Use when asked to review a PR, review code, post review comments, test PR changes on a cluster, deploy PR images for testing, or do a full PR review. Also use when given a PR URL or number and asked for feedback, or when user mentions "review this PR", "PR review", "code review", or "test this PR on my cluster".
4
5
---
5
6
6
7
<cli_setup>
7
-
This skill uses the orchestrator CLI for activity tracking. **Set up first:**
8
+
9
+
For cluster testing workflows, set up the orchestrator CLI:
8
10
9
11
```bash
10
12
RHDH=../rhdh/scripts/rhdh
@@ -14,24 +16,20 @@ RHDH=../rhdh/scripts/rhdh
14
16
15
17
<essential_principles>
16
18
17
-
<principlename="ensure_cluster">
18
-
Always verify the user has a running RHDH cluster with `oc` access before deploying PR bundles.
19
-
If no cluster or no RHDH instance, provision one using `redhat-developer/rhdh-test-instance` — see `rhdh-repos.md` for details on that repo's capabilities.
20
-
Don't just tell the user to set things up — do it.
19
+
<principlename="layered_architecture">
20
+
Reviews follow a three-layer pipeline: **fetch** (forge-specific) → **analyze** (agnostic) → **post** (forge-specific). Each layer produces a structured artifact for the next. The analyze layer never calls forge-specific CLIs.
21
+
</principle>
22
+
23
+
<principlename="verify_findings">
24
+
Reviewers will produce false positives. Verify every finding against actual code at HEAD before including it. Drop findings that reference non-existent code, duplicate existing comments, misread the code, or conflict with codebase conventions.
21
25
</principle>
22
26
23
-
<principlename="use_pr_comment_images">
24
-
Extract image URLs from PR comments posted by CI — never construct image URLs manually.
25
-
The tag format includes PR number + commit SHA, which only CI knows.
26
-
See `references/operator-pr-images.md` for extraction commands.
27
+
<principlename="user_confirms_before_posting">
28
+
Present the full review draft — summary, inline comments with file:line, and event type — to the user before posting. Proceed only after confirmation.
27
29
</principle>
28
30
29
31
<principlename="deploy_full_bundle">
30
-
Deploy the full PR bundle/manifests, not just the operator binary image.
31
-
PR changes to CRDs, RBAC, default config, or bundle metadata are baked into the OLM bundle or install.yaml manifests — a binary-only image swap misses them and the operator may fail to reconcile.
32
-
For OLM-managed installs, replace the CatalogSource with the PR's `operator-catalog` image so OLM reinstalls the full bundle (CRDs, RBAC, CSV, deployment).
33
-
For non-OLM installs, fetch and apply the PR branch's `install.yaml` (CRDs, RBAC, ConfigMaps, Deployment) with the CI-built operator image substituted in.
34
-
Both paths preserve existing Backstage CRs, config, and Keycloak state — only the operator-side resources are replaced.
32
+
For cluster testing: deploy the full PR bundle/manifests, not just the operator binary image. PR changes to CRDs, RBAC, default config, or bundle metadata are baked into the OLM bundle or install.yaml — a binary-only image swap misses them.
35
33
</principle>
36
34
37
35
</essential_principles>
@@ -40,35 +38,96 @@ Both paths preserve existing Backstage CRs, config, and Keycloak state — only
40
38
41
39
## What would you like to do?
42
40
43
-
### PR Review Tasks
41
+
### Code Review
42
+
43
+
1.**Review PR code** — Analyze a PR diff, generate findings, and post inline comments
44
+
2.**Review PR code (analysis only)** — Analyze without posting (e.g., to review locally or post later)
44
45
45
-
*For testing PR changes on a live RHDH cluster*
46
+
### Cluster Testing (rhdh-operator PRs)
46
47
47
-
1.**Review rhdh-operator PR** — Deploy PR operator bundle on cluster and get review checklist
48
+
3.**Test PR on cluster** — Deploy PR operator bundle on a live RHDH cluster and verify changes
49
+
50
+
### Combined
51
+
52
+
4.**Full review** — Code review + post to GitHub + cluster testing
48
53
49
54
**Wait for response before proceeding.**
50
55
51
56
</intake>
52
57
53
58
<routing>
54
59
55
-
### PR Review Routes
56
-
57
60
| Response | Workflow |
58
61
|----------|----------|
59
-
| 1, "operator", "rhdh-operator", a PR number, "review" | Route to `workflows/review-operator-pr.md`|
62
+
| 1, "review", "review PR", "code review", a PR URL or number |`workflows/fetch-github.md` → `workflows/review-code.md` → `workflows/post-to-github.md`|
**To route:** Read `workflows/review-operator-pr.md` and follow its process.
67
+
### Routing rules
68
+
69
+
1.**PR URL or number with no other context**: default to route 1 (code review + post).
70
+
2.**rhdh-operator PR detected** (repo is `redhat-developer/rhdh-operator`): suggest route 4 (full review) but let the user choose.
71
+
3.**"review" without "post" or "cluster"**: route 1.
72
+
4.**All routes start with fetch.** The fetch workflow produces a context artifact consumed by all downstream workflows.
73
+
74
+
### Forge detection
75
+
76
+
Currently GitHub only. Detect from URL pattern or `gh` CLI availability.
77
+
78
+
When GitLab support is added: `fetch-gitlab.md` and `post-to-gitlab.md` will slot into the same pipeline. The analyze workflow (`review-code.md`) is forge-agnostic and needs no changes.
Examples of review perspectives and the signals that suggest them. These are starting points, not a fixed roster — choose perspectives that fit the PR's actual content. Invent new ones when the PR calls for it (e.g., devil's advocate, agile coach, skill expert, domain specialist).
4
+
5
+
## Common perspectives
6
+
7
+
| Perspective | Focus | Prompt guidance |
8
+
|-------------|-------|-----------------|
9
+
|**Correctness**| Logic bugs, edge cases, error handling, off-by-ones, null/undefined paths | "Find bugs that would reach production. Ignore style." |
| Linked issues exist | Requirements | Any `Fixes #N` or Jira key in the body |
30
+
31
+
## Choosing perspectives
32
+
33
+
Read the PR's diff, metadata, and linked issues. Create perspectives based on what matters most for this specific change — the examples above are a starting point, not a menu to pick from.
34
+
35
+
## Reviewer coordination
36
+
37
+
When using multiple reviewers:
38
+
39
+
- Each gets the diff, linked requirements, and their focus area
40
+
- Instruct them to read source at HEAD, not just the diff
41
+
- Encourage cross-checking — reviewers should challenge overlapping or contradictory findings
0 commit comments