Did you try the inverted branch choose strategy in git plugin advanced
settings on the job configuration page?

-- Sami

2012/4/4 John Hinnegan <john.hinne...@gmail.com>:
> I have 2 auto-build jobs in Jenkins for 1 real project (git repo).
>
> Job 1 builds and tests any branch pushed to the repo
>
> Job 2 builds only the master branch, and, upon successful tests, pushes the
> change out to our testing env.
>
> Both jobs will trigger if a push to master happens. Setting Job 2 to only
> build after Job 1 causes Job 2 to build master, even if no changes have
> happened (since Job 1 builds for any branch).
>
> I would like to only run Job 2 if Job 1 succeeded, and was for master. Or to
> have Job 1 build for any branch but master. Or maybe put a pre-build check
> for Job 2 that stops the build unless a change has occurred since last
> build?
>
> Any way I can get this working?
> Or maybe I can put the deploy into Job 1 only if it's building on branch
> master?

Reply via email to