Skipping polling from the git plugin is not an option for branch sources The branch source tracks last revision built for each branch and fires a build of the current revision is not equal to the last.
What you want is a build step that stops the build with an "ignore" status of some sort. On Sat 25 Mar 2017 at 09:52, Idan Adar <[email protected]> wrote: > As Mark mentioned, the alternative is to trigger an exception... (which > will in turn show the row in red color). > I do it as follows. After checking out, if a git commit includes "[ci > skip]" I use a "success" keyword (this keyword does not exit) hence the > build stops. > > I would love for this keyword to exist, so that the job will stop with a > green row instead of a red row... Is this possible? > > stage ("Checkout SCM") { > steps { > script { > STAGE_NAME = "Checkout SCM" > > checkout scm > result = sh (script: "git log -1 | grep '.*\\[ci skip\\].*'", > returnStatus: true) > if (result == 0) { > echo ("'ci skip' spotted in git commit. Aborting.") > success ("'ci skip' spotted in git commit. Aborting.") > } > } > } > } > > -- > 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/cd25bb36-d893-4281-a04e-d5a6bb54f6b8%40googlegroups.com > <https://groups.google.com/d/msgid/jenkinsci-users/cd25bb36-d893-4281-a04e-d5a6bb54f6b8%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- Sent from my phone -- 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/CA%2BnPnMymwUSu6%2BDiUQpgwZdVwZ4t%3DQP81DggRo6iwMX%3Dr_CWSA%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
