diff --git a/scripts/commit-msg.py b/scripts/commit-msg.py index 7de6dc3df..e743b34d3 100755 --- a/scripts/commit-msg.py +++ b/scripts/commit-msg.py @@ -9,11 +9,11 @@ FAIL_C = "\033[91m" END_C = "\033[0m" -JIRA_REGEX = "(SPII|PCRM|NEMS|KF|IGWAY|NRL|APM|APMSPII|SPY3|SPINECLI)\-(\d+)" # Example match: SPII-12345 +JIRA_REGEX = "(SPII|PCRM|NEMS|KF|IGWAY|NRL|APM|APMSPII|SPY3|SPINECLI)\\-(\\d+)" # Example match: SPII-12345 FEATURE_REGEX = ( - "feature\/\w+\-(\w+\-\d+)\-" # Example match: feature/das-SPII-12345-foo + "feature\\/\\w+\\-(\\w+\\-\\d+)\\-" # Example match: feature/das-SPII-12345-foo ) -OLD_FEATURE_REGEX = "feature\/\w+\-(\d+)\-" # Example match: feature/das-12345-foo +OLD_FEATURE_REGEX = "feature\\/\\w+\\-(\\d+)\\-" # Example match: feature/das-12345-foo sys.stdin = open("/dev/tty") # Ensure that input can be taken by hook MSG_FILE = sys.argv[1] # commit-msg hook provides file name as first arg