Last active
September 6, 2017 09:23
-
-
Save Bazze/21a896ad6c8c318d7b53ed7ab7a36379 to your computer and use it in GitHub Desktop.
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
#!/usr/bin/env bash | |
# Usage: ./extract-jira-issues.sh <git revision/tag/branch> <git revision/tag/branch> | |
START_REV=$1 | |
END_REV=$2 | |
JIRA_STATUSES="Done,\"Ready for QA\"" | |
JIRA_URL="https://my-jira-url.atlassian.net" | |
ISSUES=$( | |
git log ${START_REV}..${END_REV} --pretty=oneline | | |
perl -ne '{ /(\w+)-(\d+)/ && print "$1-$2\n" }' | | |
sort | uniq | xargs | | |
sed -e 's/ /%2C/g' | |
) | |
echo "${JIRA_URL}/issues/?jql=issue in (${ISSUES}) and status in (${JIRA_STATUSES})" | sed -e 's/ /%20/g' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment