Thursday, May 28, 2020

Writing useful commit comments

Some thoughts on writing useful [concise, descriptive, contextual] commit comments. Applies to all SCM systems (Git, Subversion, etc.)

A properly formed Git commit subject line should always be able to complete the following sentence:

  • If applied, this commit will your subject line here
For example:
  • If applied, this commit will refactor subsystem X for readability
  • If applied, this commit will update getting started documentation
  • If applied, this commit will remove deprecated methods
  • If applied, this commit will release version 1.0.0
  • If applied, this commit will merge pull request #123 from user/branch
Chris Beam

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.