It was released as part of git plugin versions git-3.1.0, git-3.0.5, git-3.0.4, git-3.0.3, git-3.0.2, git-3.0.1, git-2.6.5, git-2.6.4, git-2.6.2, and git-2.6.1.
Mark Waite On Sun, Mar 19, 2017 at 2:07 AM <[email protected]> wrote: > Was this merged already? > Is it safe to use checkout scm within for parallel jobs? > > > On Thursday, September 22, 2016 at 6:53:06 AM UTC+3, Mark Waite wrote: > > The intent of the checkout scm step is that it takes a single revision, > and uses that revision for the duration of the job. > > Unfortunately, a bug was found during discussions after Jenkins World > which seem to indicate that there area cases where git plugin 2.5.3 and > beyond risks not checking out the same revision for every use of "checkout > scm" within a single job. > > The fix is in > https://github.com/jenkinsci/git-plugin/commit/cd6c7cdcba29f5c3615ad35d690678ebd5694348 > . > > Tests which confirm the fix has the desired behavior are in > https://github.com/jenkinsci/git-plugin/commit/e15a431a62781c6081c57354a33a7e148a4452a1 > and > https://github.com/jenkinsci/git-plugin/commit/fcbdc768536c2c5286680734bbedc64fec0103c2 > . > > Those fixes have not yet been included in a plugin release. > > Mark Waite > > On Wed, Sep 21, 2016 at 9:38 PM sleipnir <[email protected]> wrote: > > Hi > > I was playing with JenkinsFiles and Organization folders (multi-branch > pipeline) and I was wondering: > Is there is any guarantee the 'checkout scm' command would checkout the > exact same revision on all node, even if new commits are pushed before the > build is finished ? > Also, I saw an environment variable that gives the branch name > (BRANCH_NAME) but nothing for the revision. > Do I have to call a git command after the 'checkout scm' command to > extract the sha1 so I can stamp the build output properly ? (something like > 'git rev-parse HEAD') > > Here's a test jenkinsfile I'm using: > > stage 'build' > > parallel ( > BuildDebug: { node { > checkout scm > > > }}, > BuildRelease: { node { > checkout scm > > }} > ) > > Thanks > > -- > You received this message because you are subscribed to the Google Groups > "Jenkins Users" group. > > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > > > To view this discussion on the web visit > https://groups.google.com/d/msgid/jenkinsci-users/4fb3bb94-a954-4e2e-aecf-5786432aa08b%40googlegroups.com > <https://groups.google.com/d/msgid/jenkinsci-users/4fb3bb94-a954-4e2e-aecf-5786432aa08b%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > > -- > You received this message because you are subscribed to the Google Groups > "Jenkins Users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/jenkinsci-users/e5220124-473a-4552-bbf4-38a7f73a4220%40googlegroups.com > <https://groups.google.com/d/msgid/jenkinsci-users/e5220124-473a-4552-bbf4-38a7f73a4220%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/CAO49JtG_LpaihuAHJN%3D-Nxpq2jOtMr%3D64QgC9B3oejw1c%3DekEA%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
