no one knows how to limit a cron to a branch in a Jenkinsfile ?

Le vendredi 10 septembre 2021 à 15:28:01 UTC+2, Francois Marot a écrit :

>
> Hello all,
>
> I set up a cron trigger in my Jenkinsfile of the master branch, but now 
> new branches are also built by this trigger at night. I would like to limit 
> this behavior to my 'master' branch.
> How would you do that ?
> I know I can abort the build if I detect that that a cron triggered it but 
> I dream of a simpler way.
>
> pipeline {
>     triggers {
>         cron('H 5 * * 1,3,5')
>     }
>     ...
>
> regards
> François
>

-- 
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/23742ebb-c721-4bf4-a77c-c57f4c63f322n%40googlegroups.com.

Reply via email to