Details
-
Type:
New Feature
-
Status: Resolved (View Workflow)
-
Priority:
Minor
-
Resolution: Fixed
-
Component/s: token-macro-plugin
-
Labels:None
-
Similar Issues:
Description
I have a job monitoring a git repository, which triggers jobs which are not looking at git.
I currently rename builds on the git job to the abbreviated sha1. I would like to rename the child jobs too. I can't use a parameter file or environment variable, as the file i have created with the hash in it doesn't exist until after the copy artefact plugin has operated, during the build steps - which is too late.
There should be a simple PARENT_JOB_NAME variable I can use.
Code changed in jenkins
User: Alex Earl
Path:
src/main/java/org/jenkinsci/plugins/tokenmacro/impl/UpstreamRunNameMacro.java
src/test/java/org/jenkinsci/plugins/tokenmacro/TokenMacroTest.java
src/test/java/org/jenkinsci/plugins/tokenmacro/impl/UpstreamRunNameMacroTest.java
http://jenkins-ci.org/commit/token-macro-plugin/c2fa8e11bc074025f3df1236c347968e4bfe0412
Log:
Fix
JENKINS-27542Add UPSTREAM_RUN_NAME macro that will have the display name for the upstream job.
Compare: https://github.com/jenkinsci/token-macro-plugin/compare/490f3f734794...c2fa8e11bc07