Assuming you are using the freestyle job type, you could make the further build steps part of a Conditional steps build step. The status for the condition could be determined by running your batch script, or by creating (or not) a file in the workspace during your batch script as a flag on whether to continue.
-Eric On Thu, May 24, 2018 at 12:23 AM, <[email protected]> wrote: > I've been scouring the internet for a way to do this and have had no > success > > We use git as our source control > Our jenkins server is running in windows > I am using windows batch scripts for several build tasks > I have written a batch script that checks the commit message for a > specific bit of text that indicates that we don't want jenkins to build > this job. At the end of this script I would like jenkins to halt all > further build steps and mark the job as a success. > > I could easily do this with: > exit 1 > but that would result in the job being marked as failed, and then a bunch > of people receive emails when they are not supposed to. > > Any advice? > Thanks. > > SubC Imaging is a division of SubC Control Ltd. For additional information > about SubC Imaging, please visit our website at http://www.subcimaging.com > <http://www.subccontrol.com/> > > > This email and any attached files are intended for the sole use of the > primary and copied addressee(s) and may contain privileged and/or > confidential information. > > > Any distribution, use or copying by any means of this information is > strictly prohibited. If you received this email in error, please delete it > immediately and notify the sender. > > -- > 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/316344fa-c1b1-4701-bc00-963d21798c2b%40googlegroups. > com > <https://groups.google.com/d/msgid/jenkinsci-users/316344fa-c1b1-4701-bc00-963d21798c2b%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- *Eric Pyle* Siemens PLM Software Lebanon, New Hampshire +1 603-277-3060 (T) [email protected] http://www.siemens.com -- 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/CAPrXuH19YqL%2ByNGqTza%3Du_0G6G25XmsLHf%3Dz39DyeWtBoTFAyw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
