fix(entrypoint): use bash condition correctly

This commit is contained in:
Alexander Jank 2020-12-20 00:12:55 +01:00
parent c94954550f
commit 532659cc88
No known key found for this signature in database
GPG Key ID: 77D8FCD22C49149B

View File

@ -14,7 +14,7 @@ REPOSITORY_NAME=$(basename "${GITHUB_REPOSITORY}")
[[ ! -z ${INPUT_PASSWORD} ]] && SONAR_PASSWORD="${INPUT_PASSWORD}" || SONAR_PASSWORD=""
if [! -f "${GITHUB_WORKSPACE}/sonar-project.properties"]; then
if [[ ! -f "${GITHUB_WORKSPACE}/sonar-project.properties" ]]; then
[[ -z ${INPUT_PROJECTKEY} ]] && SONAR_PROJECTKEY="${REPOSITORY_NAME}" || SONAR_PROJECTKEY="${INPUT_PROJECTKEY}"
[[ -z ${INPUT_PROJECTNAME} ]] && SONAR_PROJECTNAME="${REPOSITORY_NAME}" || SONAR_PROJECTNAME="${INPUT_PROJECTNAME}"
[[ -z ${INPUT_PROJECTVERSION} ]] && SONAR_PROJECTVERSION="" || SONAR_PROJECTVERSION="${INPUT_PROJECTVERSION}"