Add setting of projectVersion

This commit is contained in:
Dariusz Dwornikowski 2020-07-14 09:45:39 +02:00
parent accc346655
commit 5379cc65b4
2 changed files with 6 additions and 1 deletions

View File

@ -16,7 +16,11 @@ inputs:
required: false required: false
default: "" default: ""
projectName: projectName:
description: "The project's name. If not given name will be generated by SonarQube" description: "Name of the project that will be displayed on the web interface."
required: false
default: ""
projectVersion:
description: "The project version."
required: false required: false
default: "" default: ""
projectBaseDir: projectBaseDir:

View File

@ -13,6 +13,7 @@ fi
[[ ! -z ${INPUT_PASSWORD} ]] && SONAR_PASSWORD="${INPUT_PASSWORD}" || SONAR_PASSWORD="" [[ ! -z ${INPUT_PASSWORD} ]] && SONAR_PASSWORD="${INPUT_PASSWORD}" || SONAR_PASSWORD=""
[[ -z ${INPUT_PROJECTKEY} ]] && SONAR_PROJECTKEY="${PWD##*/}" || SONAR_PROJECTKEY="${INPUT_PROJECTKEY}" [[ -z ${INPUT_PROJECTKEY} ]] && SONAR_PROJECTKEY="${PWD##*/}" || SONAR_PROJECTKEY="${INPUT_PROJECTKEY}"
[[ -z ${INPUT_PROJECTNAME} ]] && SONAR_PROJECTNAME="${PWD##*/}" || SONAR_PROJECTKEY="${INPUT_PROJECTNAME}" [[ -z ${INPUT_PROJECTNAME} ]] && SONAR_PROJECTNAME="${PWD##*/}" || SONAR_PROJECTKEY="${INPUT_PROJECTNAME}"
[[ -z ${INPUT_PROJECTVERSION} ]] && SONAR_PROJECTVERSION="${PWD##*/}" || SONAR_PROJECTKEY="${INPUT_PROJECTVERSION}"
sonar-scanner \ sonar-scanner \