aboutsummaryrefslogtreecommitdiffhomepage
path: root/githooks/commit-msg
diff options
context:
space:
mode:
Diffstat (limited to 'githooks/commit-msg')
-rwxr-xr-xgithooks/commit-msg2
1 files changed, 1 insertions, 1 deletions
diff --git a/githooks/commit-msg b/githooks/commit-msg
index b0c7e5b..61c2844 100755
--- a/githooks/commit-msg
+++ b/githooks/commit-msg
@@ -125,7 +125,7 @@ if [[ -z ${gitbranch} ]]; then
fi
# Extract issue number from branch name.
-local issue_number="$(echo "${gitbranch}" | grep -o '[0-9][0-9]*')"
+local issue_number="$(echo "${gitbranch}" | grep -o '[0-9][0-9]*' | head -1)"
if [[ -z ${issue_number} ]]; then
# Failed to extract. Leave the commit message as it is.
return 0