diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml index 5d0f337..eec67a7 100644 --- a/.github/workflows/qa.yml +++ b/.github/workflows/qa.yml @@ -19,12 +19,13 @@ jobs: - name: Run action with args uses: ./ with: - args: -Dsonar.someArg=aValue -Dsonar.scanner.dumpToFile=./output.properties + args: >- + "-Dsonar.someArg=a value with spaces" -Dsonar.scanner.dumpToFile=./output.properties env: SONAR_HOST_URL: http://not_actually_used - name: Assert run: | - ./test/assertFileContains ./output.properties "sonar.someArg=aValue" + ./test/assertFileContains ./output.properties "sonar.someArg=a value with spaces" projectBaseDirInputTest: name: > 'projectBaseDir' input diff --git a/entrypoint.sh b/entrypoint.sh index 2bdd5d5..205251c 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -37,5 +37,6 @@ fi unset JAVA_HOME -sonar-scanner $debug_flag -Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR} ${INPUT_ARGS} +eval "args=(${INPUT_ARGS})" +sonar-scanner $debug_flag "-Dsonar.projectBaseDir=${INPUT_PROJECTBASEDIR}" "${args[@]}"