From: Thanh Ha Date: Thu, 23 Jul 2020 17:54:14 +0000 (-0400) Subject: Decode Base64 before parsing Gerrit comment X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=releng%2Fbuilder.git;a=commitdiff_plain;h=74feceab4b44278720ac168d025e3a8989d4ad85 Decode Base64 before parsing Gerrit comment The Gerrit Trigger plugin appears to be sending us a Base64 encoded value now so we need to decode it first before we can parse it. Issue: RELENG-151 Change-Id: I07f40f787a9c8c5167bdb9a7b4a491e55a80f569 Signed-off-by: Thanh Ha --- diff --git a/jjb/integration/multipatch-distribution.sh b/jjb/integration/multipatch-distribution.sh index 67e5ba7e6..a054e1fa0 100755 --- a/jjb/integration/multipatch-distribution.sh +++ b/jjb/integration/multipatch-distribution.sh @@ -28,6 +28,9 @@ export GIT_COMMITTER_NAME="Multipatch Job" # Extract a list of patches per project from an comment trigger. An example is: # multipatch-build:openflowplugin:45/69445/1,genius:46/69446/1,netvirt:47/69447/1 if [ -n "$GERRIT_EVENT_COMMENT_TEXT" ]; then + # Decode Base64 before parsing text. + GERRIT_EVENT_COMMENT_TEXT=$(echo "$GERRIT_EVENT_COMMENT_TEXT" | base64 -d) + if [[ "$GERRIT_EVENT_COMMENT_TEXT" == *fast* ]]; then BUILD_FAST="true" PATCHES_TO_BUILD=$(echo "$GERRIT_EVENT_COMMENT_TEXT" | grep 'multipatch-build-fast:')