New hook for enforcing branch name

Use a regex to validate the naming convention the branch should follow.
If it's not correct, it fails.
This commit is contained in:
Mariano Anaya 2024-05-31 13:08:20 +02:00
parent ee30c6ada9
commit 86d5ab84cb
4 changed files with 58 additions and 0 deletions

View file

@ -204,3 +204,10 @@
language: python
types: [text]
stages: [commit, push, manual]
- id: enforce-branch-name
name: enforce branch name
description: Make sure the current branch follows one of the accepted patterns.
entry: enforce-branch-name
language: python
pass_filenames: false
always_run: true