-
Notifications
You must be signed in to change notification settings - Fork 618
Migration Guides
Version 1.4 contains some changes that may require you to adapt your Pipeline jobs. FreeStyle and similar jobs aren't affected as for those the migration happens automatically during the upgrade.
If you had configured some of the following options for the Build when a change is pushed to GitLab
trigger of your Pipeline jobs you have to do the following:
This can now be done by the pipeline step addGitLabMRComment
which takes the argument comment
. To achieve the same behavior as before add this to your Pipeline job:
def resultIcon = currentBuild.result == 'SUCCESS' ? ':white_check_mark:' : ':anguished:'
addGitLabMRComment comment: "$resultIcon Jenkins Build $currentBuild.result\n\nResults available at: [Jenkins [$env.JOB_NAME#$env.BUILD_NUMBER]]($env.BUILD_URL)"
Note: You have to ensure that currentBuild.result
is set to the correct value depending on your build.
This can now be done by the pipeline step addGitLabMRComment
which takes the argument comment
. To achieve the same behavior as before add this to your Pipeline job:
addGitLabMRComment comment: currentBuild.result == 'SUCCESS' ? ':+1:' : ':-1:'
Note: You have to ensure that currentBuild.result
is set to the correct value depending on your build.
This can now be done by the pipeline step acceptGitLabMR
. To achieve the same behavior as before add this to your Pipeline job:
if currentBuild.result == 'SUCCESS' {
acceptGitLabMR()
}
Note: You have to ensure that currentBuild.result
is set to the correct value depending on your build.