Skip to content

feat: added skill to update a repo to the latest rc#132

Open
dlabaj wants to merge 1 commit into
patternfly:mainfrom
dlabaj:rc-update
Open

feat: added skill to update a repo to the latest rc#132
dlabaj wants to merge 1 commit into
patternfly:mainfrom
dlabaj:rc-update

Conversation

@dlabaj

@dlabaj dlabaj commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Adds a skill to update any project to the latest patternfly rc.

Summary by CodeRabbit

  • New Features
    • Added a new migration skill for updating PatternFly dependencies to the latest release-candidate versions, including install, build, test, and retry guidance.
  • Documentation
    • Updated migration docs and skill listings to include the new release-candidate update workflow.
    • Expanded usage notes with step-by-step instructions and troubleshooting tips.

@dlabaj dlabaj requested a review from jpuzz0 July 7, 2026 18:29
@coderabbitai

coderabbitai Bot commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

Adds a new "PF Release Candidate Update" skill to the migration plugin: a SKILL.md workflow document and a latest-release-candidates.sh script that resolves PatternFly release-candidate versions from npm, updates package.json dependency sections, and guides install/build/test/fix steps. Plugin documentation and README files are updated to reference the new skill.

Changes

PF Release Candidate Update skill addition

Layer / File(s) Summary
Plugin/README registration
CONTRIBUTING-SKILLS.md, PLUGINS.md, plugins/migration/README.md
Migration plugin table and README entries list the new pf-release-candidate-update skill and its purpose.
Skill metadata, overview, and prerequisites
plugins/migration/skills/pf-release-candidate-update/SKILL.md
Defines frontmatter, title/overview, prerequisites (run location, network access, script presence), and a step checklist.
Workflow steps: resolve, update, install, build, test
plugins/migration/skills/pf-release-candidate-update/SKILL.md
Documents resolving RC versions, updating package.json sections with exact pins, detecting package manager for install, building, and running tests.
Failure remediation, reporting, and monorepo notes
plugins/migration/skills/pf-release-candidate-update/SKILL.md
Documents a diagnose-fix-retest loop, final reporting requirements, monorepo guidance, and a common-issues symptom/fix table.
latest-release-candidates.sh implementation
plugins/migration/skills/pf-release-candidate-update/scripts/latest-release-candidates.sh
Resolves RC versions from npm dist-tags/versions, outputs JSON/lines, updates package.json via inline Node script, and handles CLI mode selection.

Estimated code review effort: 2 (Simple) | ~15 minutes

Possibly related PRs

  • patternfly/ai-helpers#95: Both PRs modify the migration plugin's plugins/migration/README.md and related plugin documentation structure.

Suggested reviewers: jpuzz0

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title is clearly related to the main change: adding a skill for updating a repo to the latest release candidate.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Warning

Review ran into problems

🔥 Problems

Linked repositories: Public OSS repositories can only analyze public repositories installed in this organization. No linked repositories were analyzed; skipped anthropics/claude-plugins-official.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@plugins/migration/skills/pf-release-candidate-update/SKILL.md`:
- Around line 17-20: The workflow examples in SKILL.md are inconsistent about
how to invoke latest-release-candidates.sh, which breaks the skill-local path
convention. Update the Step 2 guidance and any other references so they all use
the same $CLAUDE_SKILL_DIR-based path to scripts under
plugins/migration/skills/pf-release-candidate-update, rather than calling bash
latest-release-candidates.sh without a path or implying a copy step.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 520414bd-fd17-42ec-84bf-03f52a59f11a

📥 Commits

Reviewing files that changed from the base of the PR and between 4bbd3c3 and 2bca92f.

📒 Files selected for processing (5)
  • CONTRIBUTING-SKILLS.md
  • PLUGINS.md
  • plugins/migration/README.md
  • plugins/migration/skills/pf-release-candidate-update/SKILL.md
  • plugins/migration/skills/pf-release-candidate-update/scripts/latest-release-candidates.sh

Comment on lines +17 to +20
- Run from the **target project root** (the repo with `package.json`), not from `ai-helpers`.
- Network access for `npm view` and package install.
- The skill script lives at `plugins/migration/skills/pf-release-candidate-update/scripts/latest-release-candidates.sh` in ai-helpers. Copy it into the target project or invoke it by absolute path.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Use the skill-local script path consistently.

Step 2 calls bash latest-release-candidates.sh with no path, so the workflow only works after an unstated copy step. Point every example at the same $CLAUDE_SKILL_DIR-based path instead.

🛠️ Proposed fix
- The skill script lives at `plugins/migration/skills/pf-release-candidate-update/scripts/latest-release-candidates.sh` in ai-helpers. Copy it into the target project or invoke it by absolute path.
+ The skill script lives in this skill directory. Reference it with `$CLAUDE_SKILL_DIR/scripts/latest-release-candidates.sh`.
@@
- bash latest-release-candidates.sh --update package.json
+ bash "$CLAUDE_SKILL_DIR/scripts/latest-release-candidates.sh" --update package.json

As per path instructions, use $CLAUDE_SKILL_DIR to reference files or scripts relative to the skill directory.

Also applies to: 66-68

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@plugins/migration/skills/pf-release-candidate-update/SKILL.md` around lines
17 - 20, The workflow examples in SKILL.md are inconsistent about how to invoke
latest-release-candidates.sh, which breaks the skill-local path convention.
Update the Step 2 guidance and any other references so they all use the same
$CLAUDE_SKILL_DIR-based path to scripts under
plugins/migration/skills/pf-release-candidate-update, rather than calling bash
latest-release-candidates.sh without a path or implying a copy step.

Source: Path instructions

# ./latest-release-candidates.sh --json # JSON object of package -> version
# ./latest-release-candidates.sh --update [package.json] # update PF deps in package.json

set -euo pipefail

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The fallback path (line 44) and --update mode (line 91) both call node -e, but the script doesn't check for Node.js first. Would a command -v node guard near the top help? CONTRIBUTING-SKILLS.md L234–237 shows the pattern. The SKILL.md would also need a ## Requirements section noting the Node.js dependency.

### Diagnosis order

1. **Read the error output** — note the first failing file and whether it is a type error, import error, or runtime/test failure.
2. **Import paths** — load `pf-import-checker` and fix invalid `@patternfly/*` imports (charts, chatbot, component-groups dynamic paths, missing CSS).

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These skill names don't match what's on mainpf-import-checker is actually pf-import-check, pf-component-structure is pf-component-check, and pf-class-migration-scanner doesn't exist in the repo. Would describing the capability instead work better here? e.g., "scan for invalid @patternfly/* import paths" — that way the instructions work regardless of which skills or MCP tools the user has installed.


| Symptom | Likely fix |
|---------|------------|
| `Module not found: @patternfly/...` | Wrong import path; see `pf-import-checker` |

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same name issue in the common issues table — pf-import-checker should either be the correct name (pf-import-check) or a capability description to stay consistent with the skill name fix above.

@@ -0,0 +1,154 @@
---
name: pf-release-candidate-update
description: >-

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Skill descriptions get loaded into a limited context window alongside every other installed skill — longer descriptions are more likely to get cut off. Would a shorter version keep the trigger words intact? e.g., Update @patternfly/* npm dependencies to the latest release candidate versions. Use when testing the next PF release or bumping to RC packages.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants