본문 바로가기
Git

깃 커밋메시지 작성법 - How to write Git commit messages

by sycareer 2021. 5. 31.

커밋 메시지 규칙

1. 제목과 본문을 빈 행으로 구분할 것.

2. 커밋메시지에 공백오류가 포함되지 않도록 할 것.

3. 불필요한 구두점 넣지 말 것.

4. 제목을 마침표로 끝내지 말 것.

5. 제목과 각 문단의 시작은 대문자로 할 것.

6. 제목은 명령조로 쓸 것.

7. 본문에는 무엇(what)이 바뀌었는지, 왜(why) 그것을 만들었는지 쓸 것.(Not how)

8. 검토자가 기존 문제가 어떤 것이었는지 이해하려한다고 가정하지 말고, 문제를 추가했는지 확인할 것.

9. 따로 설명이 필요없는 코드라고 생각하지 말 것.

10. 팀에서 정한 커밋관습을 따를 것.

 

 


 

1. Separate the subject from the body with a blank line

2. Your commit message should not contain any whitespace errors

3. Remove unnecessary punctuation marks

4. Do not end the subject line with a period

5. Capitalize the subject line and each paragraph

6. Use the imperative mood in the subject line

7. Use the body to explain what changes you have made and why you made them.

8. Do not assume the reviewer understands what the original problem was, ensure you add it.

9. Do not think your code is self-explanatory

10. Follow the commit convention defined by your team

 

 

Reference : https://www.freecodecamp.org/news/writing-good-commit-messages-a-practical-guide/