summaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
authorKristijan Husak <husakkristijan@gmail.com>2020-04-15 17:27:42 +0200
committerJesse Duffield <jessedduffield@gmail.com>2020-04-20 18:47:50 +1000
commit6cf75af0afbec83a269b313d9253bb32b758737d (patch)
treeb9555bdd2ee6d052788a5397d280ae961706e0c6 /docs
parent304607ae5d4b18acaeffaa980b97ba3984ece311 (diff)
Add option to set predefined commit message prefix. Fixes #760.
Diffstat (limited to 'docs')
-rw-r--r--docs/Config.md16
1 files changed, 16 insertions, 0 deletions
diff --git a/docs/Config.md b/docs/Config.md
index 3d9caba36..4becd364f 100644
--- a/docs/Config.md
+++ b/docs/Config.md
@@ -269,3 +269,19 @@ Where:
- `gitDomain` stands for the domain used by git itself (i.e. the one present on clone URLs), e.g. `git.work.com`
- `provider` is one of `github`, `bitbucket` or `gitlab`
- `webDomain` is the URL where your git service exposes a web interface and APIs, e.g. `gitservice.work.com`
+
+## Predefined commit message prefix
+In situations where certain naming pattern is used for branches and commits, pattern can be used to populate
+commit message with prefix that is parsed from the branch name.
+
+Example:
+* Branch name: feature/AB-123
+* Commit message: [AB-123] Adding feature
+
+```yaml
+ git:
+ commitPrefixes:
+ my_project: # This is repository folder name
+ pattern: "^\\w+\\/(\\w+-\\w+)"
+ replace: "[$1] "
+```