Should commit messages be written in present or past tense? [closed]

So which is it that you think is better and more intuitive?

Fixed the XXX bug in YYY
Fix the XXX bug in YYY
Fixes the XXX bug in YYY
Fixing the XXX bug in YYY

Please provide your rationales. Note I am asking from your general perspective, meaning you should not try to associate this with your preferred svn/cvs tools or programming languages, but rather think of it as something that should/can be applied to any tools and programming languages.


I think of these messages as they appear to other developers. They don't yet have the changes applied, and there is the implicit question, "what will applying this changeset/patch do?" It will "Fix the XXX bug in YYY"!

For other verbs writing them as a command seems more natural, and works better if you have a specific goal up-front—you can literally write the commit summary along with up-front tests before the work is done.

I don't put a huge amount of weight on it, but for me this is the path of least resistance while maintaining consistentency.


I personally go with past tense ("fixed") since by the time I get to committing the bug is fixed (or I wouldn't be committing).


I prefer to see commit messages in present tense. That way the message describes what the diff does (because you might pull that diff or even that whole commit into a different branch). Thus, the commit message does not describe what it "did" do... It describes what the commit itself "does" do. So it should be in present tense.

Imagine looking at a diff in isolation and trying to decide whether you will apply it. It makes no sense for it to have a title in the past tense.