Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
giscience
big-data
ohsome
libs
username-resolver
Commits
84e5743f
Verified
Commit
84e5743f
authored
Apr 19, 2022
by
Johannes Visintini
Browse files
Jenkins: update sonarcloud integration CLI parameters
parent
1de2282b
Pipeline
#3341
passed with stage
in 0 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Jenkinsfile
View file @
84e5743f
...
...
@@ -62,7 +62,17 @@ pipeline {
steps
{
script
{
withSonarQubeEnv
(
'sonarcloud GIScience/ohsome'
)
{
sh
"mvn $MAVEN_GENERAL_OPTIONS sonar:sonar -Dsonar.branch.name=${env.BRANCH_NAME}"
SONAR_CLI_PARAMETER
=
""
if
(
env
.
CHANGE_ID
)
{
SONAR_CLI_PARAMETER
+=
" "
+
"-Dsonar.pullrequest.key=${env.CHANGE_ID} "
+
"-Dsonar.pullrequest.branch=${env.CHANGE_BRANCH} "
+
"-Dsonar.pullrequest.base=${env.CHANGE_TARGET}"
}
else
{
SONAR_CLI_PARAMETER
+=
" "
+
"-Dsonar.branch.name=${env.BRANCH_NAME}"
}
sh
"mvn $MAVEN_GENERAL_OPTIONS sonar:sonar ${SONAR_CLI_PARAMETER}"
}
report_basedir
=
"/srv/reports/${REPO_NAME}/${VERSION}_${env.BRANCH_NAME}/${env.BUILD_NUMBER}_${LATEST_COMMIT_ID}"
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment