We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent aaf76b1 commit aae5650Copy full SHA for aae5650
1 file changed
pre_commit_hooks/jira_id_hook.py
@@ -19,7 +19,7 @@ def main():
19
branch_name = get_current_branch_name()
20
21
# Check for a pattern matching 'something_' after a '/'
22
- if re.search(r'\/.+-', branch_name):
+ if re.search(r'\/.+-', branch_name) and ('feature' in branch_name or 'bugfix' in branch_name):
23
# Extract the prefix from the branch name (everything after the first '/' and before the first '_')
24
match = re.search(r'.*\/([A-Z]+-\d+).*', branch_name)
25
if match:
0 commit comments