From a2c5d78d191bc461791a7a67ff2a80e9aacb65e1 Mon Sep 17 00:00:00 2001 From: Useroth <37159550+Useroth@users.noreply.github.com> Date: Mon, 14 Sep 2020 02:07:43 +0200 Subject: [PATCH] Pruning mentions from mirrored commit messages. (#446) * Let's disable docker publishing * Update merge-upstream-pull-request.sh --- skyrat/tools/merge-upstream-pull-request.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/skyrat/tools/merge-upstream-pull-request.sh b/skyrat/tools/merge-upstream-pull-request.sh index 7803fe7a3d1..023e9e24730 100755 --- a/skyrat/tools/merge-upstream-pull-request.sh +++ b/skyrat/tools/merge-upstream-pull-request.sh @@ -78,6 +78,8 @@ if echo "$CHERRY_PICK_OUTPUT" | grep -i 'error: mainline was specified but commi # Add all files onto this branch git add -A . git -c core.editor=true cherry-pick --continue + # Prune any possible mentions from the commit message. + git commit -m "$(git -c core.editor=true log -1 --pretty=%B | sed 's/@/@ /g')" --amend done else echo "Cherry-picking: $MERGE_SHA" @@ -85,17 +87,24 @@ if echo "$CHERRY_PICK_OUTPUT" | grep -i 'error: mainline was specified but commi # Add all files onto this branch git add -A . git -c core.editor=true cherry-pick --continue + # Prune any possible mentions from the commit message. + git commit -m "$(git -c core.editor=true log -1 --pretty=%B | sed 's/@/@ /g')" --amend fi else # Add all files onto this branch echo "Adding files to branch:" git add -A . + # Prune any possible mentions from the commit message. + git commit -m "$(git -c core.editor=true log -1 --pretty=%B | sed 's/@/@ /g')" --amend fi # Commit these changes echo "Commiting changes" git -c core.editor=true commit --allow-empty -m "$2" +# Prune any possible mentions from the commit message. +git commit -m "$(git -c core.editor=true log -1 --pretty=%B | sed 's/@/@ /g')" --amend + # Push them onto the branch echo "Pushing changes" git push -u origin "$BASE_BRANCH_NAME$1"