Please follow the format at your best to save your future self some time.
Format
<PREFIX> - [ISSUE_ID] <MESSAGE>
Things inside <> is required; [] is optional.
Prefix
Prefix Abbr.
Prefix meaning
Description
Example
ADD
Add
You've added something.
New feature implemented.
FIX
Fix
You've fixed something.
A bug was being fixed.
IMP
Improvement
You've improved something.
Optimized a piece of code.
UPD
Update
You've updated something.
Refactored a piece of code or updated the README.md file.
DEL
Delete
You've deleted something.
Deleted a piece of temporary code.
OTH
Other
You've done something that cannot be categorized as any of the above.
Initial commit.
To clarify, the difference between IMP and UPD is that IMP brings some positive effects to the code (presumably); UPD only brings changes to the code (possibly positive, but not that explicit).
Message
Would be better to be < 50 words. However, if there's something that cannot be briefly described, it's fine to go over 50 words. Just don't be too much. You'll want to read the commit history as a story containing a lot of short sentences.
If your commit relates to an issue, mention it.
Examples
Added a new map-generating function.
ADD - new map-generating function
Fixed a bug in stop data parsing, which originally reads the data at column 3 as column 4.
FIX - Misread in stop data parsing process
Implemented a feature listed in issues as #87, which is to incorporate ML to automatically create an optimal route map for Madison.
ADD - #87 create optimal route for Madison
A bug was found after you published #87 which actually creates the worst route map.
FIX - #87 created worst map instead of the best map
I am not doing the best practice according to this because I think that it might be too hard for us to suddenly adopt it. Also, it would be time-consuming for learning this, possibly losing the focus of what should we do now in the limited time.
If you want to fix the error yielded by Github Actions, please amend the commit, squash it, then force push it to your dev branch. I believe that we don't want to see a commit history containing full of fixes that actually only do a small fix of a task. For how to do this, check #10.
Please follow the format at your best to save your future self some time.
Format
Things inside <> is required; [] is optional.
Prefix
ADD
FIX
IMP
UPD
DEL
OTH
To clarify, the difference between
IMP
andUPD
is thatIMP
brings some positive effects to the code (presumably);UPD
only brings changes to the code (possibly positive, but not that explicit).Message
Would be better to be < 50 words. However, if there's something that cannot be briefly described, it's fine to go over 50 words. Just don't be too much. You'll want to read the commit history as a story containing a lot of short sentences.
If your commit relates to an issue, mention it.
Examples
Added a new map-generating function.
ADD - new map-generating function
Fixed a bug in stop data parsing, which originally reads the data at column 3 as column 4.
FIX - Misread in stop data parsing process
Implemented a feature listed in issues as #87, which is to incorporate ML to automatically create an optimal route map for Madison.
ADD - #87 create optimal route for Madison
A bug was found after you published #87 which actually creates the worst route map.
FIX - #87 created worst map instead of the best map
Notes
Additional reads: How to Write a Git Commit Message (& why it matters)
If you want to fix the error yielded by Github Actions, please amend the commit, squash it, then force push it to your dev branch. I believe that we don't want to see a commit history containing full of fixes that actually only do a small fix of a task. For how to do this, check #10.