一键导入
pull-request
Generate a PR title and description following project conventions, then create or update the PR via gh CLI
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Generate a PR title and description following project conventions, then create or update the PR via gh CLI
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Navigation-only skill for individual actions in netcracker/qubership-workflow-hub. Use when a workflow needs to consume a specific Qubership action (Docker build/push, version/tag rendering, Maven/npm/Python publishing, package cleanup, Helm charts, security scans, etc.) and you need to find the right action and read its authoritative README. All rules (pinning, permissions, anti-hallucination, naming) live in qubership-workflow-conventions — this skill does not restate them.
Markdownlint ruleset from super-linter. Apply when writing or editing any .md file.
Single source of truth for Qubership GitHub Actions workflows. Use when designing, writing, reviewing, or debugging .github/workflows/*.yml that consume actions or templates from netcracker/qubership-workflow-hub or Netcracker/.github.
Audit GitHub Actions workflow and action.yml files for security issues using zizmor rules, then fix violations
Update or create documentation for a specific action or reusable workflow based on git diff and action.yml
Audit files for EditorConfig violations (final newline, trailing whitespace, indent, line endings) and fix them in-place
| name | pull-request |
| description | Generate a PR title and description following project conventions, then create or update the PR via gh CLI |
| arguments | ["mode","base-branch"] |
Generate a pull request title and body following project conventions.
Default flow: preview first — show title + body, wait for confirmation, then execute gh.
$mode — update to update an existing open PR; omit to create a new PR.$base-branch — branch to compare against. Overrides auto-detected base (see step 2).PR title format:
<type>(<scope>): <imperative statement>
feat, fix, docs, refactor, chore, perf, ci, build, test, deprecate, revert.actions/metadata-action, docs, .github/workflows.Verify gh is installed and authenticated. If not — stop immediately and inform the user:
install gh CLI and run gh auth login.
update → MODE = update; second argument (if any) = BASE_ARGMODE = create; first argument (if any) = BASE_ARGCollect in parallel:
CURRENT_BRANCHbaseRefName, number, url, state, isDraft);
if no PR exists or the command fails, treat as empty → EXISTING_PRDEFAULT_BRANCH; if unavailable, fall back to mainResolve BASE in priority order:
$BASE_ARG if providedEXISTING_PR.baseRefName if EXISTING_PR is non-empty and EXISTING_PR.state == "OPEN"DEFAULT_BRANCH from gh repo viewmain as final fallback if gh repo view fails — warn the userIf CURRENT_BRANCH == BASE — inform the user and stop.
git log BASE..HEAD --oneline
git diff BASE..HEAD --name-only
git diff BASE..HEAD
→ COMMITS, CHANGED_FILES, FULL_DIFF
If COMMITS is empty — inform the user there are no commits ahead of BASE and stop.
Before starting, print:
Running lint audit on changed files…
Audit all changed files in sequence. Print a one-line status before each sub-audit:
[1/3] EditorConfig…, then apply
.claude/skills/editorconfig/SKILL.md rules to all changed files, fix with Edit. [2/3] Markdown lint…, then apply
.claude/skills/markdown-rules/SKILL.md rules to .md files, fix with Edit. [3/3] Security audit (zizmor)…, then apply
.claude/skills/zizmor/SKILL.md rules to .yml/.yaml workflow and action files,
fix with Edit. Note: this step may fetch remote SHAs for unpinned actions — it can
take a moment.Fix everything that is safe to auto-fix. For violations that cannot be safely auto-fixed —
collect them into AUDIT_WARNINGS and continue. Never block the preview or the PR flow.
From CHANGED_FILES:
actions/<name>/ → SCOPE = actions/<name>.github/workflows/ → SCOPE = .github/workflowsdocs/ → SCOPE = docspackages/<name>/ → SCOPE = packages/<name>From commit messages and FULL_DIFF:
| Type | When |
|---|---|
feat | New feature or capability |
fix | Bug fix |
docs | Documentation only |
refactor | Restructuring without behaviour change |
chore | Maintenance, deps, config |
perf | Performance improvement |
ci | CI/CD workflows or configuration |
build | Build system |
test | Adding or updating tests |
deprecate | Marking something deprecated |
revert | Reverting a previous commit |
Issue: search commit messages for Fixes #NNN, Closes #NNN, Resolves #NNN,
Related to #NNN. If found → ISSUE_REF = full reference. If not → ISSUE_REF = none.
Breaking: flag if commit contains BREAKING CHANGE or ! after type, or if required
inputs/outputs are removed or renamed in action.yml / workflow yml.
Title: <type>(<scope>): <imperative statement>
Body: read .github/pull_request_template.md as the skeleton. Fill each section:
| Section | How to fill |
|---|---|
## Summary | 2–3 sentences: what changed, why, key result. Be specific — component names, inputs, behaviour. |
## Issue | ISSUE_REF if found; otherwise "No linked issue." Remove placeholder text. |
## Breaking Change? | Check [x] Yes or [x] No. If Yes — describe impact. Remove placeholder text. |
## Scope / Project | SCOPE value from step 6. Remove placeholder text. |
## Implementation Notes | Bullet list of technical decisions and non-obvious changes. For docs/chore PRs with small diffs: "Documentation update only — no behaviour change." |
## Tests / Evidence | Test command + result, dry-run output, or manual validation steps. |
## Additional Notes | Limitations, follow-ups, reviewer instructions. If none: "None." |
If .github/pull_request_template.md does not exist — generate body with these same
sections using standard markdown headings.
Do not leave any placeholder or instructional text from the template in the output.
Show the user:
Title: <TITLE>
Body:
<BODY>
If AUDIT_WARNINGS is non-empty — show them as a warning block before the preview.
Wait for user confirmation before proceeding. Ask: "Create/update the PR with this title and body?"
If MODE = create:
EXISTING_PR exists and state is OPEN → inform user (show number and URL), ask
whether to update it or create a new one. Wait for answer.gh pr create --title "<TITLE>" --body "<BODY>" --base BASE
If MODE = update:
update. Stop.gh pr edit --title "<TITLE>" --body "<BODY>"
After success, print the PR URL.
| Situation | Behaviour |
|---|---|
gh not installed or not authenticated | Caught in step 1 — stop immediately. Inform user: install gh CLI and run gh auth login. |
gh repo view fails (no remote) | Fall back to main as BASE. Warn user that BASE could not be auto-detected. |
No .github/pull_request_template.md | Generate body with standard sections (see step 9). |
| No commits ahead of BASE | Stop. Inform user. |
| No issue reference found | Write "No linked issue." in ## Issue — do not leave placeholder. |
EXISTING_PR absent in update mode | Stop. Inform user. Suggest running without update. |
EXISTING_PR present in create mode | Ask user: update existing PR or create a new one? Wait for answer. |
| Audit finds non-auto-fixable violations | Add to AUDIT_WARNINGS shown at preview. Never block the flow. |