Last active
April 4, 2017 19:09
-
-
Save benkutil/f1966d45773769fd0b3f00e1b9dbd773 to your computer and use it in GitHub Desktop.
Script to run as part of Jenkins validation of pull requests. Helps to ensure all merged PRs have a Jira ticket in their title
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PRMATCH=`echo "$ghprbPullTitle" | sed -n "/release notes\|\[[A-Za-z0-9]\+-[0-9]\+\]/Ip" | |
if [[ -n "$ghprbPullTitle" ]] && [[ -z "$PRMATCH" ]]; then | |
echo "$ghprbPullTitle does not contain a JIRA ticket" | |
exit 1 | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment