Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save maicol07/325cdc1e1002be451fa5146a4b2bebe4 to your computer and use it in GitHub Desktop.
Save maicol07/325cdc1e1002be451fa5146a4b2bebe4 to your computer and use it in GitHub Desktop.
GitHub Copilot Commit Message Instructions. Based on https://github.com/SimonSkoda13/Copilot-commit-message-instructions

Commit Message Instructions

  • Use conventional commit message format.
  • The commit message should have a short description (50 characters or less) followed by a blank line and then a longer description.
  • The short description should be in the format: <type>(<scope>):<icon> <short description>
    • type: The type of change (e.g., feat, fix, docs, style, refactor, test, chore).
      • feat: ✨ A new feature
      • fix: πŸ› A bug fix
      • docs: πŸ“ Documentation only changes
      • style: πŸ’„ 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 feature
      • test: βœ… Adding missing tests or correcting existing tests
      • chore: πŸ”§ Changes to the build process or auxiliary tools and libraries such as documentation generation
      • perf: ⚑️ A code change that improves performance
      • ci: πŸ‘· Changes to CI configuration files and scripts
      • build: πŸ—οΈ Changes that affect the build system or external dependencies
      • revert: βͺ Reverts a previous commit
      • wip: 🚧 Work in progress
      • security: πŸ”’ Security-related changes
      • i18n: 🌐 Internationalization and localization
      • a11y: β™Ώ Accessibility improvements
      • ux: 🎨 User experience improvements
      • ui: πŸ–ŒοΈ User interface changes
      • config: πŸ”§ Configuration file changes
      • deps: πŸ“¦ Dependency updates
      • infra: 🌐 Infrastructure changes
      • init: πŸŽ‰ Initial commit
      • analytics: πŸ“ˆ Analytics or tracking code
      • seo: πŸ” SEO improvements
      • legal: βš–οΈ Licensing or legal changes
      • typo: ✏️ Typo fixes
      • comment: πŸ’¬ Adding or updating comments in the code
      • example: πŸ’‘ Adding or updating examples
      • mock: πŸ€– Adding or updating mocks
      • hotfix: πŸš‘ Critical hotfix
      • merge: πŸ”€ Merging branches
      • cleanup: 🧹 Code cleanup
      • deprecate: πŸ—‘οΈ Deprecating code or features
      • move: 🚚 Moving or renaming files
      • rename: ✏️ Renaming files or variables
      • split: βœ‚οΈ Splitting files or functions
      • combine: 🧬 Combining files or functions
      • add: βž• Adding files or features
      • remove: βž– Removing files or features
      • update: ⬆️ Updating files or features
      • downgrade: ⬇️ Downgrading files or features
      • patch: 🩹 Applying patches
      • optimize: πŸ› οΈ Optimizing code
      • docs: πŸ“ Documentation changes
      • test: βœ… Adding or updating tests
      • fix: πŸ› Bug fixes
      • feat: ✨ New features
      • style: πŸ’„ Code style changes (formatting, etc.)
      • refactor: ♻️ Code refactoring
      • perf: ⚑️ Performance improvements
      • ci: πŸ‘· Continuous integration changes
      • build: πŸ—οΈ Build system changes
      • revert: βͺ Reverting changes
      • wip: 🚧 Work in progress
      • security: πŸ”’ Security improvements
      • i18n: 🌐 Internationalization changes
      • a11y: β™Ώ Accessibility improvements
      • ux: 🎨 User experience improvements
      • ui: πŸ–ŒοΈ User interface changes
      • config: πŸ”§ Configuration changes
      • deps: πŸ“¦ Dependency updates
      • infra: 🌐 Infrastructure changes
      • init: πŸŽ‰ Initial commit
      • analytics: πŸ“ˆ Analytics changes
      • seo: πŸ” SEO improvements
      • legal: βš–οΈ Legal changes
      • typo: ✏️ Typo fixes
      • comment: πŸ’¬ Comment changes
      • example: πŸ’‘ Example changes
      • mock: πŸ€– Mock changes
      • hotfix: πŸš‘ Hotfix changes
      • merge: πŸ”€ Merge changes
      • cleanup: 🧹 Cleanup changes
      • deprecate: πŸ—‘οΈ Deprecation changes
      • move: 🚚 Move changes
      • rename: ✏️ Rename changes
      • split: βœ‚οΈ Split changes
      • combine: 🧬 Combine changes
      • add: βž• Add changes
      • remove: βž– Remove changes
      • update: ⬆️ Update changes
      • downgrade: ⬇️ Downgrade changes
      • patch: 🩹 Patch changes
      • optimize: πŸ› οΈ Optimize changes
    • scope: The scope of the change (e.g., component or file name). Include this if the change is specific to a particular part of the codebase.
  • short description: A brief summary of the change.
  • The long description should provide additional context and details about the change.
    • Explain why the change was made.
    • Describe what is being used and why.
    • Include any relevant information that might be useful for understanding the change in the future.
    • Reference any related issues or pull requests at the end of the long description.
  • If the commit fixes an issue or task, include Fixes #<issue-number> or Closes #<issue-number> at the end of the long description.
  • If the commit introduces a breaking change, include BREAKING CHANGE: <description of the breaking change> at the end of the long description.

Example

Commit Message Example

feat(auth): ✨ Add user authentication

Added user authentication using JWT. This includes login, registration, and token verification endpoints.

β€’ Implemented JWT-based authentication.
β€’ Added login and registration endpoints.
β€’ Added middleware for token verification.

Fixes #123

Breaking Change Example

refactor(api): ♻️ Update API endpoints

Refactored the API endpoints to follow RESTful conventions. This change affects all existing API calls.

β€’ Updated endpoint URLs to follow RESTful conventions.
β€’ Modified request and response formats.

BREAKING CHANGE: All existing API calls need to be updated to the new endpoint URLs.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment