File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -206,6 +206,26 @@ changes any given branch is introducing before looking at the code.
206
206
- ``testing/ `` or ``test/ ``: Improvements or changes to testing.
207
207
- ``release/ ``: Releases (see below).
208
208
209
+ Enforcing branch-name conventions
210
+ ---------------------------------
211
+
212
+ `GitHub rulesets
213
+ <https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/managing-rulesets/about-rulesets> `_
214
+ allow to enforce branch-name conventions. To do so, create a new ruleset named
215
+ ``conventional-commits ``, then select the following configuration:
216
+
217
+ - Enforcement status: ``Active ``
218
+ - Target branches:
219
+ - Include: ``All branches ``
220
+ - Exclude: ``main ``, ``gh-pages ``
221
+
222
+ - Restrict branch names:
223
+ - Applies to: ``Branch name ``
224
+ - Requirement: ``Must match a given regex pattern ``
225
+ - Matching pattern: ``^(feat|fix|chore|docs|style|refactor|test|perf|ci|build|dependabot|release)\/.* ``
226
+ - Description: ``Branch name must match the conventional commits pattern ``
227
+
228
+
209
229
Push your branch
210
230
----------------
211
231
You can’t perform that action at this time.
0 commit comments