Skip to content

Navigation Menu

Sign in
Sign up

Latest commit

History

5 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

Conventional Commits Instructions for VS Code & Copilot

A structured, XML-based instruction template for VS Code and GitHub Copilot to automatically generate clean, single-line Conventional Commits with expressive emoji prefixes in English.

πŸ’‘ Why This Exists

VS Code's automatic commit message generator can produce inconsistent formatting, missing types, or redundant file listings when using free-form prompts.

An XML instruction template enforcing scopeless, emoji-prefixed Conventional Commits 1.0.0 standards.

πŸš€ Quick Setup

1. Add the Instruction File

Create the instruction file inside your project's .github directory:

# Path: .github/commit-message-instructions.md

Copy the contents of commit-message-instructions.md directly into that file.

2. Configure VS Code Settings

Link the file inside your project or workspace settings.

Project-Level Settings (.vscode/settings.json):

{
 "github.copilot.chat.commitMessageGeneration.instructions": [
 {
 "file": ".github/commit-message-instructions.md"
 }
 ]
}

Workspace Settings (.code-workspace):

{
 "folders": [
 {
 "path": "."
 }
 ],
 "settings": {
 "github.copilot.chat.commitMessageGeneration.instructions": [
 {
 "file": ".github/commit-message-instructions.md"
 }
 ]
 }
}

🎨 Commit Types & Emoji Mapping

All generated commits strictly follow the <emoji> <type>: <description> syntax without parentheses or scopes:

Emoji Type Purpose Example
✨ feat A new feature ✨ feat: add OAuth2 login support
πŸ› fix A bug fix πŸ› fix: resolve null pointer exception in user service
πŸ“ docs Documentation only changes πŸ“ docs: update installation instructions
🎨 style Formatting, whitespace, or UI styling 🎨 style: format code with prettier
♻️ refactor Code restructuring without logic changes ♻️ refactor: extract validation logic to middleware
⚑ perf Performance improvements ⚑ perf: implement lazy loading for gallery
πŸ§ͺ test Adding or updating tests πŸ§ͺ test: add unit tests for login validation
πŸ“¦ build Build system or external dependencies πŸ“¦ build: upgrade React to v19
πŸ€– ci CI/CD configuration files and scripts πŸ€– ci: add GitHub Actions workflow for testing
πŸ”§ chore Setup, tooling, configs, or dependencies πŸ”§ chore: initialize next.js project with tailwind css
βͺ revert Reverting previous commits βͺ revert: revert "feat: add OAuth2 login support"
πŸ’₯ feat!/fix! Breaking changes πŸ’₯ feat!: change response format for user endpoints

πŸ“‹ Core Rules

  1. English Only: All commit messages are written strictly in English.
  2. No Scopes: No parentheses or scopes (use <emoji> <type>: <description> directly).
  3. Imperative Mood: Present-tense action verbs (add not added or adds).
  4. Casing & Punctuation: Entire subject line is lowercase; no trailing period.
  5. Length Limits: Subject line limited to 50 characters when possible, max 72.
  6. Single-Line for Setup & Chores: Initial setup, chores, configuration, and dependencies never generate bodies, file lists, or bullet points.
  7. Body Constraints: Optional bodies are reserved only for complex features or breaking changes, wrapped at 72 characters and explaining what and why, not how.

πŸ™ Acknowledgments

This instruction template is inspired by and adapted from:

πŸ“„ License

MIT License. See LICENSE for more information.

About

XML-based Conventional Commits instruction template with emoji prefixes for VS Code and GitHub Copilot.

Topics

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

AltStyle γ«γ‚ˆγ£γ¦ε€‰ζ›γ•γ‚ŒγŸγƒšγƒΌγ‚Έ (->γ‚ͺγƒͺγ‚ΈγƒŠγƒ«) /