From 4038150246e08d0d6a8cd668f310c4a7e2c00975 Mon Sep 17 00:00:00 2001 From: Misko Hevery Date: Sat, 8 Aug 2015 19:23:14 -0700 Subject: [PATCH] chore(ci): presubmit-pr-888 adds Closes #888 on merge Closes #1234 --- scripts/ci/presubmit-queue-success.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/scripts/ci/presubmit-queue-success.sh b/scripts/ci/presubmit-queue-success.sh index 7c0393b1c3..27b78c2bf4 100755 --- a/scripts/ci/presubmit-queue-success.sh +++ b/scripts/ci/presubmit-queue-success.sh @@ -22,6 +22,15 @@ if [ "$TRAVIS_REPO_SLUG" = "angular/angular" ]; then git stash git fetch upstream master git rebase upstream/master + + if [[ $TRAVIS_BRANCH == *"-pr-"* ]]; then + PR_NO=`echo presubmit-mhevery-pr-1234 | sed -e 's/^.*-pr-//'` + if echo $PR_NO | egrep -q '^[0-9]+$'; then + echo "Adding Closes #$PR_NO" + git filter-branch -f --msg-filter "cat /dev/stdin && echo && echo Closes \#$PR_NO" HEAD~1..HEAD + fi + fi + if git push upstream HEAD:master; then echo "$TRAVIS_BRANCH has been merged into master, deleting..." git push upstream :"$TRAVIS_BRANCH"