An Interest In:
Web News this Week
- April 1, 2024
- March 31, 2024
- March 30, 2024
- March 29, 2024
- March 28, 2024
- March 27, 2024
- March 26, 2024
March 21, 2021 07:37 am GMT
Original Link: https://dev.to/intrepid_ishan/git-commit-message-convention-that-you-can-follow-1709
Git commit message convention that you can follow!
Motivation of this blog is to curate all information at one place and to make more people aware about standards followed by industry.
Let's get started.....
A typical git commit message will look like
<type>(<scope>): <subject>
"type" must be one of the following mentioned below!
build
: Build related changes (eg: npm related/ adding external dependencies)chore
: A code change that external user won't see (eg: change to .gitignore file or .prettierrc file)feat
: A new featurefix
: A bug fixdocs
: Documentation related changesrefactor
: A code that neither fix bug nor adds a feature. (eg: You can use this when there is semantic changes like renaming a variable/ function name)perf
: A code that improves performancestyle
: A code that is related to stylingtest
: Adding new test or making changes to existing test
"scope" is optional
- Scope must be noun and it represents the section of the section of the codebase
- Refer this link for example related to scope
"subject"
- use imperative, present tense (eg: use "add" instead of "added" or "adds")
- don't use dot(.) at end
- don't capitalize first letter
Refer this link for more practical examples of commit messages
References:
Original Link: https://dev.to/intrepid_ishan/git-commit-message-convention-that-you-can-follow-1709
Share this article:
Tweet
View Full Article
Dev To
An online community for sharing and discovering great ideas, having debates, and making friendsMore About this Source Visit Dev To