Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

5 branches: (master, develop, test1, test2, test3)

We need to triger trigger a build only from two branches: (master, develop)

If we leave the field "Branch Options" with parametr the parameter "Build all" - it will build from all branches
If we leave the field "Branch Options" with parametr the parameter "Build from" - master - it will trigger to build Jenkins from the master branch, same with develop.

...

  1. Select “Build from“ and enter branch names separated by white space: “master develop“

  2. Select “Build RegExp“ and enter regexp based expression: “master|develop“

Note:

Note

Jenkins jobs must be configured for

the branches

master branch.

Yes

Alternatively, branch parameter can be set when using integration with Git Plugin. On hook settings set “Parameters“ field to this:

...

TARGET_BRANCH={BRANCH}.