Skip to main content

setup-conventional-commits

Enforce conventional commit format via a PreToolUse hook on Bash that intercepts git commit commands. Replaces commitlint + husky entirely. Use when setting up conventional commits, commit message validation, or enforcing commit format standards.

معلومات المصدر

المستودع
redpanda-data/ui-harness
آخر نشاط في المصدر
٨ مايو ٢٠٢٦ في ١١:٢١
لغة SKILL.md المكتشفة
الإنجليزية
النجوم
٣٤
التفرعات
٤

خيارات التثبيت

يُحدَّد Prompt الذي يراجع المصدر أولًا بشكل افتراضي. يمكنك التبديل إلى أمر مباشر أو تنزيل نسخة محلية.

مراجعة ملفات المصدر

اقرأ SKILL.md وأي ملفات مرافقة يعرضها SkillsMP قبل أن تقرر التثبيت.

مستكشف الملفات
4 ملفات

عرض SKILL.md

SKILL.md
تعليمات المصدر · معاينة للقراءة فقط
name
setup-conventional-commits
description
Enforce conventional commit format via a PreToolUse hook on Bash that intercepts git commit commands. Replaces commitlint + husky entirely. Use when setting up conventional commits, commit message validation, or enforcing commit format standards.
# Setup Conventional Commits PreToolUse hook (Bash) intercept `git commit -m` -> validate format. Replace commitlint + husky (zero deps). ## Format ``` type(scope): description ``` - **type**: feat|fix|refactor|style|test|docs|chore|perf|ci|build|revert - **scope**: required, lowercase in parens -- `feat(webui):`, `fix(backend):` - **description**: lowercase first letter, no trailing period, 5-72 chars - **body**: optional, encourage feat/fix ## Steps 1. Copy `scripts/conventional-commits-check.sh` + `scripts/_hook-lib.sh` -> `.claude/hooks/`. `chmod +x`. 2. Add to `.claude/settings.json`: PreToolUse (Bash): `.claude/hooks/conventional-commits-check.sh` 3. Optional: `codex-compat` for Codex `.codex/hooks.json` ## Verify - [ ] Block: `git commit -m "bad message"`, `git commit -m "feat: missing scope"`, `git commit -m "feat(ui): A"` (uppercase) - [ ] Allow: `git commit -m "feat(ui): add button component"` - [ ] Ignore non-commit Bash commands
عرض على GitHub