Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-23485

TokenMacro for getting a version value stored in environment variable

    XMLWordPrintable

Details

    Description

      TokenMacro for getting a version value stored in environment variable.
      As a parameter it is possible to remove -SNAPSHOT from the version.
      Example:

      ${ENV_VERSION,var="POM_VERSION",stripSnapshot=true}
      ${ENV_VERSION,var="POM_VERSION"}
      

      Attachments

        Issue Links

          Activity

            patbos Patrik Boström created issue -
            patbos Patrik Boström made changes -
            Field Original Value New Value
            Description TokenMacro for getting a version value stored in environment variable.
            As a parameter it is possible to remove -SNAPSHOT from the version.
            TokenMacro for getting a version value stored in environment variable.
            As a parameter it is possible to remove -SNAPSHOT from the version.
            Example:
            ${ENV_VERSION,var="POM_VERSION",stripSnapshot=true}
            ${ENV_VERSION,var="POM_VERSION"}
            patbos Patrik Boström made changes -
            Assignee Patrik Boström [ patbos ]

            I'd be interesting in this enhancement, with my particular use case being the "Stage Name", "Task Name" fields, where these two could have dynamic values based on Job Parameters.

            On a side note, I feel that the title of this JIRA ticket could be made more specific. It wasn't explicit to me where usage of the Token Macro was requested for instance.

            pmatignon Patrice Matignon added a comment - I'd be interesting in this enhancement, with my particular use case being the "Stage Name", "Task Name" fields, where these two could have dynamic values based on Job Parameters. On a side note, I feel that the title of this JIRA ticket could be made more specific. It wasn't explicit to me where usage of the Token Macro was requested for instance.

            Actually, I see that for my very use case, there is an existing ticket already created:
            https://issues.jenkins-ci.org/browse/JENKINS-20608
            So I suppose I'm still not clear what this ticket right here is requesting. Much sorry for the noise.

            pmatignon Patrice Matignon added a comment - Actually, I see that for my very use case, there is an existing ticket already created: https://issues.jenkins-ci.org/browse/JENKINS-20608 So I suppose I'm still not clear what this ticket right here is requesting. Much sorry for the noise.
            lstrojny Lars Strojny made changes -
            Description TokenMacro for getting a version value stored in environment variable.
            As a parameter it is possible to remove -SNAPSHOT from the version.
            Example:
            ${ENV_VERSION,var="POM_VERSION",stripSnapshot=true}
            ${ENV_VERSION,var="POM_VERSION"}
            TokenMacro for getting a version value stored in environment variable.
            As a parameter it is possible to remove -SNAPSHOT from the version.
            Example:
            {code}
            ${ENV_VERSION,var="POM_VERSION",stripSnapshot=true}
            ${ENV_VERSION,var="POM_VERSION"}
            {code}

            Merged PR

            patbos Patrik Boström added a comment - Merged PR
            patbos Patrik Boström made changes -
            Resolution Fixed [ 1 ]
            Status Open [ 1 ] Resolved [ 5 ]
            dawidmalina Dawid Malinowski made changes -
            Link This issue is related to JENKINS-28348 [ JENKINS-28348 ]

            Released in 0.9.6

            patbos Patrik Boström added a comment - Released in 0.9.6
            patbos Patrik Boström made changes -
            Status Resolved [ 5 ] Closed [ 6 ]
            rtyler R. Tyler Croy made changes -
            Workflow JNJira [ 156114 ] JNJira + In-Review [ 207786 ]

            People

              Unassigned Unassigned
              patbos Patrik Boström
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: