802 B
802 B
Creating good commit messages
- Use the following format:
<type>: <subject>
<body>
The valid values are: fix, feat, chore, docs Type and subject are required Body is optional
-
If there is a body, separate it from the subject with a blank line
-
Limit the subject line to 50 characters. This is not a hard limit but a rule of thumb. The subject line should explain the "what" of the logical change
-
Capitalize the subject line
-
Do not end the subject line with a period
-
Use the imperative mood in the subject line Imperative mood just means “spoken or written as if giving a command or instruction”. A few examples:
- Clean your room
- Close the door
- Take out the trash
-
Wrap the body at 72 characters
-
Use the body to explain what and why vs. how