Hi all,

I keep my Jenkinsfile in a git repo. For features and fixes, i create 
branches on this repo, each having a slightly different Jenkinsfile. I have 
a jenkins job of type multibranch pipeline, scanning these pipelines as i 
create a branch.

Assuming i have the basic declarative pipeline structure for all 
Jenkinsfiles in different branches

pipeline {
    agent any
    triggers {
        cron('H 4/* 0 0 1-5')
    }
    stages {
        stage('Example') {
            steps {
                echo 'Hello World'
            }
        }
    }
}



I sometimes want to change the cron of certain jobs, sometimes even to 
disable it. The best ideal way to do it would be to change it in 
Jenkinsfile in the GIT repo. But after changing the code and invoking 'scan 
multibranch pipeline' from Jenkins UI, it does 1 execution, which is 
something i do not want.

How can i make sure that updated settings done in Jenkinsfile are picked up 
without executing it ? And can it happen automatically immediately ?
What is the simplest way to disable a job for a while in the above setup ?

-- 
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/771929da-459f-4d6b-a224-edf5327e26dd%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to