Page History
This page describes how to phrase reasonable Writing reasonable git commit messages . We assume that you have already read and agreed in Commit rules!
Info |
---|
Reasonable commit messages facilitate:
And there are many other good reasons to write reasonable git commit messages |
Table of Contents |
---|
Intro
How to start the message
Below you will find seven good rules to write great commit messages. But before, please remember this specific Magnolia rule(s)
helps fellow team members to read and understand a project's development history at a glance.
Following this facilitates several other activities, such as documentation, root-cause analysis or reverting changes.
Example
Subject | MAGNOLIA-6223 Add improved API for resource change observation |
General rule
As compiled by Chris Beams here and listed below, we follow the seven rules of a great git commit message. "Keep in mind: This has all been said before."
TL;DR
- Separate subject from body with a blank line
- Limit the subject line to 50 characters
- Capitalize the subject line
- Do not end the subject line with a period
- Use the imperative mood in the subject line
- Wrap the body at 72 characters
- Use the body to explain what and why vs. how
On top of these rules, mind the following Magnolia-specific guidelines:
Tip |
---|
|
Note |
The subject of the commit message
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
The seven rules of a great git commit message
...
TL;DR
...
1. Separate subject from body with a blank line
...