diff --git a/.secrets.baseline b/.secrets.baseline index 1b0b26b..b949e3f 100644 --- a/.secrets.baseline +++ b/.secrets.baseline @@ -3,7 +3,7 @@ "files": "^.secrets.baseline$", "lines": null }, - "generated_at": "2023-06-02T10:46:33Z", + "generated_at": "2023-06-02T10:52:00Z", "plugins_used": [ { "name": "AWSKeyDetector" @@ -77,16 +77,6 @@ } ], "results": { - "Jenkinsfile": [ - { - "hashed_secret": "717377a7c62b9a69587e24bd2c0c8ae2ad1b9e15", - "is_secret": false, - "is_verified": false, - "line_number": 91, - "type": "Secret Keyword", - "verified_result": null - } - ], "README.md": [ { "hashed_secret": "fe568a3dee570ca32995a8e3cd6f2fc7010ad368", diff --git a/Jenkinsfile b/Jenkinsfile index 72ded46..9c1b3a8 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -68,29 +68,9 @@ pipeline { // if it is a release build then do the git tagging if (isReleaseVersion) { - - // Read the CHANGES.md to get the tag message - changes = """""" - changes += readFile('CHANGES.md') - tagMessage = """""" - for (line in changes.readLines()) { - if (!"".equals(line)) { - // append the line to the tagMessage - tagMessage = "${tagMessage}${line}\n" - } else { - break - } - } - - // Use git to tag the release at the version - // Awkward workaround until resolution of https://issues.jenkins-ci.org/browse/JENKINS-28335 - withCredentials([[$class: 'UsernamePasswordMultiBinding', credentialsId: 'github-token', usernameVariable: 'GIT_USERNAME', passwordVariable: 'GIT_PASSWORD']]) { - sh "git config user.email \"nomail@hursley.ibm.com\"" - sh "git config user.name \"Jenkins CI\"" - sh "git config credential.username ${env.GIT_USERNAME}" - sh "git config credential.helper '!echo password=\$GIT_PASSWORD; echo'" - sh "git tag -a ${version} -m '${tagMessage}'" - sh "git push origin ${version}" + gitTagAndPublish { + isDraft=true + releaseApiUrl='https://api.github.com/repos/IBM/cloudant-spring/releases' } } }