참고 (원문): https://chris.beams.io/posts/git-commit/
참고 (한글): https://meetup.toast.com/posts/106
커밋 로그 작성할 때마다 명확한 기준이 없다보니 내 멋대로 작성할 때가 많다. 괜찮은 기준인것 같아 이제부터라도 이 규칙들을 사용하려고 한다.
좀 더 자세히 봐야 할 곳은 명령형으로 작성 부분인데 핵심 요령은 다음과 같다.
"If applied, this commit will"
위 문장으로 시작한다 생각하고 Commit log를 작성하면 된다.
7번 항목도 중요한 것 같다. 결국 어떠한 작업(commit)은 어떻게 했느냐 보다 왜 했고, 무엇을 했는지가 핵심인 것 같다. 아래는 Bitcoin Core 커밋에 있는 'what changed and why'의 좋은 예제이다.
commit eb0b56b19017ab5c16c745e6da39c53126924ed6
Author: Pieter Wuille <pieter.wuille@gmail.com>
Date: Fri Aug 1 22:57:55 2014 +0200
Simplify serialize.h's exception handling
Remove the 'state' and 'exceptmask' from serialize.h's stream
implementations, as well as related methods.
As exceptmask always included 'failbit', and setstate was always
called with bits = failbit, all it did was immediately raise an
exception. Get rid of those variables, and replace the setstate
with direct exception throwing (which also removes some dead
code).
As a result, good() is never reached after a failure (there are
only 2 calls, one of which is in tests), and can just be replaced
by !eof().
fail(), clear(n) and exceptions() are just never called. Delete
them.