This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def getJiraIssueList() { | |
| /** | |
| * Returns an HTML formatted list of Jira issues related in the build. | |
| * This requires the Jenkins JIRA Pipeline Steps plugin https://jenkinsci.github.io/jira-steps-plugin/getting-started/ | |
| * @param None | |
| * @return An HTML string containing Jira issues | |
| */ | |
| def jiraServer = 'JIRA-PROD' // Define a Jira server entry in the Jenkins Jira Steps configuration named JIRA-PROD | |
| def jiraURL = "http://my.jiraserver.com:8080" // Define the Jira URL |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Updates Jira Fixed in build field with the build number and adds a comment in each related Jira issue | |
| * This requires the Jenkins JIRA Pipeline Steps plugin https://jenkinsci.github.io/jira-steps-plugin/getting-started/ | |
| * @param build Build number that will be entered in the "Fixed in Build" Jira field | |
| */ | |
| def updateJira(build) { | |
| def jiraServer = 'JIRA-PROD' // Define a Jira server entry in the Jenkins Jira Steps configuration named JIRA-PROD | |
| def jiraIssues = jiraIssueSelector(issueSelector: [$class: 'DefaultIssueSelector']) | |
| jiraIssues.each { issue -> | |
| jiraAddComment comment: "{panel:bgColor=#97FF94}{code}Code was added to address this issue in build ${build}{code} {panel}", idOrKey: issue, site: jiraServer |
NewerOlder