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

svn revision available in Ant OR automatic tagging of successful builds

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Component/s: ant-plugin
    • Labels:
      None
    • Environment:
      Platform: All, OS: All
    • Similar Issues:

      Description

      It would be quite useful to have the revision number of the source code available as an Ant variable.
      Imagine a scenario where I have an Ant task as part of my build to tag my SVN repository when my test
      suite passes. Without knowing which revision I am currently using I end up using HEAD to create a tag.
      But inbetween starting the test suite and a successful test run, someone else could've checked in
      changes that will later break the build. Because I tag using HEAD I tag their new (and untested) changes
      too.

      An alternative to providing the SVN revision number to Ant would be to provide a configuration option
      to automatically tag the build after a successful run, essentially automating the functionality added in
      1.100.

      Thanks,

      Lakhdip

        Attachments

          Activity

          Hide
          kohsuke Kohsuke Kawaguchi added a comment -

          I agree that making the revision number to the build is useful.

          As for your use case, however, you can simply tag BASE, so doing that doesn't
          require any change to Hudson.

          Show
          kohsuke Kohsuke Kawaguchi added a comment - I agree that making the revision number to the build is useful. As for your use case, however, you can simply tag BASE, so doing that doesn't require any change to Hudson.
          Hide
          kohsuke Kohsuke Kawaguchi added a comment -

          Implemented in 1.112. The env variable name is 'SVN_REVISION'

          Show
          kohsuke Kohsuke Kawaguchi added a comment - Implemented in 1.112. The env variable name is 'SVN_REVISION'
          Hide
          lnagra lnagra added a comment -

          Thanks for the exceptionally rapid turnaround Kohsuke.
          We're turning into Hudson fans over here.

          Show
          lnagra lnagra added a comment - Thanks for the exceptionally rapid turnaround Kohsuke. We're turning into Hudson fans over here.

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            lnagra lnagra
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: