-
Bug
-
Resolution: Fixed
-
Critical
-
None
-
Jenkins 2.32.1, Bitbucket Branch Source Plugin 2.0.0
Since the SCM 2.0 release, I can't find a way, in a pipeline, to get a human-readable job & branch name.
For example, if I had a BitBucket team called 'Foo', a repository called 'Bar' and a branch 'feature/KEY-Baz', it used to be possible to get a nearly human readable branch - env.BRANCH_NAME would be 'Foo/Bar%2FKEY-Baz', which was easy enough to escape to a human readable form.
Now, however, it's a shortened form, with numbers in it - something like 'Foo/Bar.qxyz123/feature-KEY.abcd12345ghij-Baz'. And there appears to be no way to get the human readable version. This has broken all of my build notification templates.
Here's my 'build started' notification, for example:
hipchatSend color: 'YELLOW', credentialId: 'HipChat', message: "<a href='${env.BUILD_URL}'>${env.JOB_NAME.replace('%2F', '/')} ${env.BUILD_NUMBER}</a> Started", notify: true, room: 'Build Server Messages', sendAs: 'Jenkins', server: '', v2enabled: false
- causes
-
JENKINS-59756 NameEncoder.decode can introduce duplicate characters per build to name-utf8.txt
- Resolved
-
JENKINS-72613 AbstractItem.doReload picks wrong name for some branch projects
- Resolved
- links to