Search code examples
groovyjenkins-workflow

Programmatically set build description


I'm trying to create a git-pull-request-checker with the workflow plugin. Is there a way to set the description for a build (e.g. to PR#123: fixed a bug) so that it becomes visible in the list of the previous builds?


Solution

  • As of 1.4, try

    currentBuild.description = 'PR#123: fixed a bug'