3 ms·
Naive question: The present tense/imperative form is a standard i kind-of adopted without ever questioning. Why is better to write in that form?
by andreasklinger 14y ago
Naive question: The present tense/imperative form is a standard i kind-of adopted without ever questioning.
Why is better to write in that form?
- cgdangelo 14y agoJust a guess, but I think it's because the message should indicate what the commit itself does, not what _you_ did to write it. For example, by merging this commit, the result is that I "Add X widget" to my code.
- themckman 14y agoThis is exactly how I describe this idea to people. I tell them to complete the following sentence. "Applying this change set will...". I've recently become less averse to verbs like fixes, updates adds, etc as I feel the sentence "The change set..." is still pretty good. The key, obviously, being you're describing the change set, not your actions.
- calinet6 14y agoWell, for one, 2-3 characters shorter ('fix' vs 'fixes', 'fixed', or 'fixing')
- brittohalloran 14y agoI think of cherry picking commits as a good scenario where this wording makes sense: "I want to... fix A, then add feature B, then change x"
- highwind 14y agoIf you are going back in time in your commits and let's say you want to go forward. It just flows better to see it as a command when going in to the future.
- ninetax 14y agoIt's to keep in form with some automatic git messages (like merge) that output in that tense. Also that is the tense the Git project committers use themselves. See: http://stackoverflow.com/questions/3580013/should-i-use-past-or-present-tense-in-git-commit-messages http://stackoverflow.com/questions/3580013/should-i-use-past... Also the past repeats: http://news.ycombinator.com/item?id=2079612 http://news.ycombinator.com/item?id=2079612 For a good laugh: http://whatthecommit.com/ http://whatthecommit.com/
- nsxwolf 14y agoSo far these responses don't convince me there is any advantage. It makes more sense to me that the trouble ticket ticket should be written in the imperative and the commit message should be past tense.