DEV Community

Cover image for WEEK1: GIT Conventional Commit
nicha
nicha

Posted on

WEEK1: GIT Conventional Commit

This will provide a set of rule to make your commit easier to read
https://www.conventionalcommits.org/en/v1.0.0/
https://gist.github.com/qoomon/5dfcdf8eec66a051ecd85625518cfd13

To summarize:

  1. feat - use when a new feature is added
  2. fix - fix a bug
  3. refactor - rewrite/restructure code (no behavior changes)
  4. perf - improve performance
  5. style - style of the file eg. white spaces, formatting, semicolon
  6. test - add test or update test
  7. docs - format the document not code
  8. build - build component eg. project version, dependencies
  9. ops - infrastructure
  10. chore - other miscellaneous commits eg. update .gitignore

NOTE:

  • Use present tense
  • Don't capitalize the first letter
  • No dot at the end

Example

docs: correct spelling of CHANGELOG
Enter fullscreen mode Exit fullscreen mode

Can also add scope like this

feat(lang): add polish language
Enter fullscreen mode Exit fullscreen mode

Top comments (0)