summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorWilly Tarreau <w@1wt.eu>2020-07-31 16:38:57 +0200
committerWilly Tarreau <w@1wt.eu>2020-07-31 16:57:09 +0200
commitf456f6f2a36f0e2ce82ef80819974cb9dc8b4e86 (patch)
tree9ed358eac56a7a47db80839f4ed0013bcf1c8bbc /scripts
parent3f3cc8c8c7cf6b464a053e3dedc6af4daa00d519 (diff)
downloadhaproxy-f456f6f2a36f0e2ce82ef80819974cb9dc8b4e86.tar.gz
SCRIPTS: git-show-backports: make -m most only show the left branch
We've never used the output of the rightmost branch with this tool, and it systematically causes two identical outputs making the job harder during backport sessions. Let's simply remove the right part when it's identical to the left one. This also adds a few line feeds to make the output more readable.
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/git-show-backports12
1 files changed, 9 insertions, 3 deletions
diff --git a/scripts/git-show-backports b/scripts/git-show-backports
index 4c6ccee76..d01f92ce1 100755
--- a/scripts/git-show-backports
+++ b/scripts/git-show-backports
@@ -249,12 +249,18 @@ dump_commit_matrix | column -t | \
echo "No missing commit to apply."
elif [ -n "$MISSING" ]; then
echo
+ echo
echo "In order to show and/or apply all leftmost commits to current branch :"
echo " git show ${left_commits[@]}"
+ echo
echo " git cherry-pick -sx ${left_commits[@]}"
echo
- echo "In order to show and/or apply all rightmost commits to current branch :"
- echo " git show ${right_commits[@]}"
- echo " git cherry-pick -sx ${right_commits[@]}"
+ if [ "${left_commits[*]}" != "${right_commits[*]}" ]; then
+ echo "In order to show and/or apply all rightmost commits to current branch :"
+ echo " git show ${right_commits[@]}"
+ echo
+ echo " git cherry-pick -sx ${right_commits[@]}"
+ echo
+ fi
fi
)