In order to fix a bug in maven-sonar.sh we should treat parameter
scan-dev-branch as string instead of boolean
Issue-ID: RELENG-4011
Signed-off-by: Kevin Sandi <ksandi@contractor.linuxfoundation.org>
Change-Id: I6aa16ef65ded5c35174003439f7d183cfa8d0fcf
--- /dev/null
+---
+fixes:
+ - |
+ Fix shell script maven-sonar.sh to handle parameter $SCAN_DEV_BRANCH
+ as string and not as boolean, so we can achieve the desired IF logic
params+=("-Dsonar.projectKey=$PROJECT_KEY")
params+=("-Dsonar.organization=$PROJECT_ORGANIZATION")
params+=("-Dsonar.login=$API_TOKEN")
- if $SCAN_DEV_BRANCH; then
+ if [ "$SCAN_DEV_BRANCH" = "True" ]; then
echo "Will scan short lived branch ..."
# shellcheck disable=SC2236
if [ ! -z ${GERRIT_CHANGE_NUMBER+x} ]; then