From 6b02b76e6c3c8030ab84d0a59e8cef05ef1ab569 Mon Sep 17 00:00:00 2001 From: Michael Fabian 'Xaymar' Dirks Date: Sat, 30 Sep 2023 05:50:41 +0200 Subject: [PATCH] Add prefix to commit titles when needed --- CONTRIBUTING.md | 49 +++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 47 insertions(+), 2 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 2bde5906..7dabee5e 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -8,20 +8,65 @@ As this is a rather large project, we have certain rules to follow when contribu ### Linear History We follow the paradigm of linear history which forbids branches from being merged, thus changes made on branches are `git rebase`d back onto the root. This simplifies the code history significantly, but makes reverting changes more difficult. -❌ `git merge` +❌ `git merge` ✅ `git rebase` ### Commits A commit should be containing a single change, even if it spans multiple units, and has the following format: ``` -short description +prefix: short description optional long description ``` The short description should be no longer than 120 characters and focus on the important things. The long description is optional, but should be included for larger changes. +#### The appropriate `prefix` + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Path(s)PrefixExample
+ data/locale + locale + data/locale/en-US.ini -> locale +
components/namename + components/shader -> shader +
+ source
+ templates
+ data
+ ui +
core + ui/main.ui -> core +
Anything elseOmit the prefix
+ +If multiple match, apply the prefix that changes the most files. If all are equal, alphabetically sort the prefixes and list comma separated. +