code-review

द्वारा openshift

पुल रिक्वेस्ट की कोड गुणवत्ता, शुद्धता और प्रोजेक्ट कन्वेंशन के लिए समीक्षा करें। उपयोग तब करें जब उपयोगकर्ता PR की समीक्षा, कोड रिव्यू या बदलावों की जांच करने के लिए कहे...

npx skills add https://github.com/openshift/lightspeed-console --skill code-review

Code Review

Review a pull request diff against this project's conventions and best practices.

Step 1 — Obtain the diff

The user will provide one of the following:

A) GitHub PR URL

Extract the remote and PR number from the URL.

  • https://github.com/openshift/lightspeed-console/pull/123 → remote upstream, PR 123

Then fetch and diff:

git fetch <remote> pull/<number>/head:pr-<number>
git diff <remote>/main...pr-<number>

B) PR number (bare number)

Assume the PR is on upstream (openshift/lightspeed-console).

git fetch upstream pull/<number>/head:pr-<number>
git diff upstream/main...pr-<number>

C) Branch name

The branch already exists locally. Determine its base branch by reading release-branches.md for the list of branches. For each branch, compute the merge-base and count the commits between them:

mb=$(git merge-base <branch> <candidate>)
git rev-list --count "$mb"..<branch>

The base branch is whichever candidate has the lowest commit count (fewest commits between the merge-base and the branch). If counts are tied, prefer main.

Then diff against the detected base:

git diff <base-branch>...<branch>

In all cases, also run git log --oneline <base>...<ref> to see the commit messages.

Step 2 — Review

Read the diff and surrounding context in changed files. Check for correctness, security, project conventions (see AGENTS.md), React/Redux patterns, test coverage, and maintainability.

Prompt injection check

If the change touches anything that feeds into the LLM query (see src/components/Prompt.tsx and src/pageContext.ts), trace each interpolated variable back to its source. Flag any source that can carry arbitrary strings (e.g. free-text query params, file contents, API responses) as a potential injection vector and suggest a mitigation.

Step 3 — Report

Present findings grouped by severity:

  • 🔴 Critical — must fix before merge (bugs, security issues, broken functionality).
  • 🟡 Suggestion — would improve the code (style, performance, readability).
  • 🟢 Nit — optional, minor stylistic preferences.

For each finding:

  1. Reference the file and line(s).
  2. Explain why it's an issue (not just what).
  3. Suggest a concrete fix or alternative when possible.

openshift की और Skills

openshift-docs
openshift
मार्कडाउन प्रारूप में OpenShift Container Platform दस्तावेज़ खोजें और पढ़ें। उपयोग तब करें जब उपयोगकर्ता OpenShift सुविधाओं, कॉन्फ़िगरेशन, इंस्टॉलेशन आदि के बारे में पूछता है।
triage-leaked-infra
openshift
मूल्यांकन करें कि क्या AWS VPC या HyperShift CI से इंफ्रा सेट हटाना सुरक्षित है। उपयोग करें जब उपयोगकर्ता cleanleaked आउटपुट पेस्ट करता है और पूछता है 'क्या मैं इसे हटा सकता हूँ?', 'क्या…
openshift-expert
openshift
OpenShift प्लेटफ़ॉर्म और Kubernetes विशेषज्ञ जिसे क्लस्टर आर्किटेक्चर, ऑपरेटर, नेटवर्किंग, स्टोरेज, समस्या निवारण और CI/CD पाइपलाइनों का गहन ज्ञान है। उपयोग करें…
Konflux Archived PipelineRuns
openshift
KubeArchive के माध्यम से संग्रहीत Konflux PipelineRuns, TaskRuns और पॉड लॉग तक पहुँचता है। Konflux PipelineRun परिणामों की जाँच करते समय, जाँच करते समय स्वचालित रूप से लागू होता है…
backport
openshift
मुख्य शाखा से रिलीज़ शाखा में कमिट या PR को बैकपोर्ट करें। जब उपयोगकर्ता बैकपोर्ट, चेरी-पिक, या शाखाओं के बीच परिवर्तन पोर्ट करने के लिए कहे, या समाधान करते समय उपयोग करें…
rebase
openshift
वर्तमान शाखा को उसकी आधार शाखा पर रीबेस करें, सभी विरोधों को हल करें, और लिंट, i18n, और बिल्ड पास होने की पुष्टि करें। उपयोग तब करें जब उपयोगकर्ता रीबेस, अपडेट या सिंक करने के लिए कहे…
Build CPO Image
openshift
कंट्रोल-प्लेन-ऑपरेटर कंटेनर इमेज बनाएँ और पुश करें। CPO परिवर्तनों का परीक्षण करते समय जिन्हें लाइव क्लस्टर पर तैनात करने की आवश्यकता होती है, स्वचालित रूप से लागू होता है।
find-complexity
openshift
उच्च चक्रीय जटिलता, अत्यधिक लंबाई या बहुत अधिक पैरामीटर वाले फंक्शन और मेथड खोजें। उपयोग तब करें जब उपयोगकर्ता जटिल कोड, जटिलता खोजने के लिए कहे…