Agent Skillsvictorgarciaesgi/regle › code-review

code-review

GitHub

用于PR合并前的强制代码审查,验证commitlint规范、pnpm工作区安装、代码Lint和Format检查,确保提交质量。

.github/skills/code-review/SKILL.md victorgarciaesgi/regle

触发场景

Pull Request 代码审查 Git 提交信息合规性检查

安装

npx skills add victorgarciaesgi/regle --skill code-review -g -y
更多选项

非标准路径

npx skills add https://github.com/victorgarciaesgi/regle/tree/main/.github/skills/code-review -g -y

不安装直接使用

npx skills use victorgarciaesgi/regle@code-review

指定 Agent (Claude Code)

npx skills add victorgarciaesgi/regle --skill code-review -a claude-code -g -y

安装 repo 全部 skill

npx skills add victorgarciaesgi/regle --all -g -y

预览 repo 内 skill

npx skills add victorgarciaesgi/regle --list

SKILL.md

Frontmatter
{
    "name": "code-review",
    "description": "Mandatory pre-commit validation for every Copilot code review on pull requests in the regle monorepo. Always verify commitlint compliance on commit titles and descriptions, pnpm workspace install, lint (vp lint), and format (vp fmt --check). Loaded on every code review — do not skip."
}

Code review — pre-commit validation

Apply on every pull request review. These checks are blocking. Do not approve a PR until all pass or the author has addressed failures.

Review checklist (run every time)

# Gate Command On failure
1 Commit messages printf '%s' "$MSG" | pnpm exec commitlint per commit Blocking comment + suggested fix
2 Workspace test -f node_modules/.modules.yaml Request pnpm install
3 Lint pnpm run lint Blocking; suggest pnpm run lint:fix
4 Format pnpm run fmt:check Blocking; suggest pnpm run fmt

Run all commands from the repo root after pnpm install.

Commit messages (commitlint)

Every commit must follow Conventional Commits per commitlint.config.ts (@commitlint/config-conventional).

type(optional-scope): imperative subject

Optional body explaining why.
  • Types: feat, fix, docs, style, refactor, perf, test, chore, ci, build
  • Subject: lowercase, imperative mood, no trailing period
  • Blank line between title and body when a body is present

Auto-fix loop

pnpm run lint:fix
pnpm run fmt
pnpm run lint
pnpm run fmt:check

Common commitlint failures

Error Fix
type-empty / subject-empty Use type: subject format
type-enum Use an allowed conventional type
subject-case Keep subject lowercase
subject-full-stop Remove trailing . from subject

版本历史

  • aeafba7 当前 2026-07-24 22:00

同 Skill 集合

.cursor/skills/antfu/SKILL.md
.cursor/skills/caveman/SKILL.md
.cursor/skills/diagnose/SKILL.md
.cursor/skills/edit-article/SKILL.md
.cursor/skills/grill-me/SKILL.md
.cursor/skills/grill-with-docs/SKILL.md
.cursor/skills/improve-codebase-architecture/SKILL.md
.cursor/skills/prototype/SKILL.md
.cursor/skills/ts-memory-baseline/SKILL.md
.cursor/skills/tsdown/SKILL.md
.cursor/skills/turborepo/SKILL.md
.cursor/skills/vite-plus/SKILL.md
.cursor/skills/vite/SKILL.md
.cursor/skills/vitepress/SKILL.md
.cursor/skills/vitest/SKILL.md
.cursor/skills/vue/SKILL.md
.cursor/skills/write-a-skill/SKILL.md
skills/regle-advanced/SKILL.md
skills/regle-migrate-vuelidate/SKILL.md
skills/regle-rules/SKILL.md
skills/regle-schemas/SKILL.md
skills/regle-typescript/SKILL.md
skills/regle/SKILL.md
.cursor/skills/zoom-out/SKILL.md

元信息

文件数
0
版本
0df09b5
Hash
6884e668
收录时间
2026-07-24 22:00

首页 - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-08-25 15:13
浙ICP备14020137号-1 $访客地图$