This document contains instructions for Claude Code to ensure all commits follow Angular commit conventions.
IMPORTANT: All commit messages MUST follow the Angular conventional commit format:
type(scope): description
[optional body]
[optional footer(s)]
- Type: Use lowercase, required
- Scope: Use lowercase, optional but recommended
- Description:
- Start with lowercase letter
- No period at the end
- Present tense, imperative mood
- Maximum 72 characters for the entire first line
Use these commit types (in order of preference):
feat: A new featurefix: A bug fixdocs: Documentation only changesstyle: Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc)refactor: A code change that neither fixes a bug nor adds a featuretest: Adding missing tests or correcting existing testschore: Changes to the build process or auxiliary tools and librariesperf: A code change that improves performanceci: Changes to CI configuration files and scriptsbuild: Changes that affect the build system or external dependenciesrevert: Reverts a previous commit
Common scopes for this project:
cli: Command-line interface changescore: Core knowhub functionalityconfig: Configuration-related changesplugins: Plugin system changessync: Synchronization functionalitytemplates: Template-related changesdocs: Documentation changestests: Test-related changesdeps: Dependency updates
- Use imperative mood: "add feature" not "added feature"
- Keep it concise but descriptive
- Explain WHAT changed, not HOW
- Start with lowercase letter
- No period at the end
feat(cli): add sync command for knowledge files
fix(config): resolve parsing error for nested configurations
docs(readme): update installation instructions
refactor(plugins): simplify plugin registry initialization
test(sync): add integration tests for GitHub plugin
chore(deps): update biome to v1.9.4
style(cli): fix formatting in help command
perf(sync): optimize file processing for large repositories
❌ Update files
❌ Fix bug
❌ Added new feature
❌ WIP: working on sync
❌ Fixed the thing that was broken
❌ docs: Update README.md.
❌ FEAT: Add new command
- No WIP commits: Always complete the work before committing
- Single responsibility: One commit should represent one logical change
- Test before commit: Ensure tests pass before committing
- Lint compliance: Code must pass linting before committing
- Release commits: The project uses semantic-release, so proper commit types are crucial for versioning
Before committing, ensure:
bun run checkpasses (Biome linting)bun testpasses (all tests)bun run buildsucceeds (TypeScript compilation)
- Release-related commits starting with
chore(release):are automatically ignored by commitlint - Breaking changes should include
BREAKING CHANGE:in the footer - Reference issues using
Closes #123orFixes #123in the footer
This project uses:
- commitlint with
@commitlint/config-conventionalto enforce these rules - husky for git hooks
- lint-staged for pre-commit checks
All commits must pass these checks to be accepted.