Skip to content

Enables support for Active Choice Plugin plugin in Jenkins Job Builder.

License

Notifications You must be signed in to change notification settings

bgaifullin/jenkins-job-builder-active-choice

Repository files navigation

Jenkins Job Builder plugin for Active Choice Parameter

https://travis-ci.org/bgaifullin/jenkins-job-builder-active-choice.png?branch=master

Enables support for Active Choice Plugin plugin in Jenkins Job Builder.

Example:

# NEW: Supports full capabilities of the Active Choice Plug-in
- job:
    name: 'TEST-jjb-active-choice-full-support'

    parameters:
        - string:
            name: STR_PARAM
            default: test

        - choice:
            name: CHOICE_PARAM
            choices:
              - choice_01
              - choice_02
              - choice_03
              - choice_04
            description: |
              Just a test parameter for used by references

        - active-choice:
            project: 'active-choice-example'
            name: ACTIVE_CHOICE_01
            description: "A parameter named ACTIVE_CHOICE_01 with options foo and bar."
            groovy:
                script: |
                    return ['foo:selected', 'bar']
                classpath: file:/tmp/aklsdjfkl.jar
                sandbox: false
            fallback:
                script: |
                    return ['Error']
            visible-item-count: 1
            choice-type: single
            filterable:  true
            filter-length: 3

        - active-choice-reactive:
            project: 'active-choice-example'
            name: ACTIVE_CHOICE_REACTIVE_01
            description: "A parameter named ACTIVE_CHOICE_REACTIVE_01 with options foo and bar."
            groovy:
                script: |
                    return ['foo:selected', 'bar']
                classpath: file:/tmp/aklsdjfkl.jar
            fallback:
                script: |
                    return ['Error']
                classpath: file:/tmp/aklsdjfkl.jar,https://lakjsdfklsdjklf/lkajsdflk.jar
                sandbox: true
            visible-item-count: 10
            reference: STR_PARAM,CHOICE_PARAM
            choice-type: multi

        - active-choice-reactive-reference:
            name: ACTIVE_CHOICE_REACTIVE_REF_01
            project: 'active-choice-example'
            description: "A parameter named ACTIVE_CHOICE_REACTIVE_REF_01 with options foo and bar."
            groovy:
                script: |
                    return ['foo:selected', 'bar']
                classpath: file:/tmp/aklsdjfkl.jar
                sandbox: true
            fallback:
                script: |
                    return ['Error']
                classpath: file:/tmp/aklsdjfkl.jar,http://lakjsdfklsdjklf/lkajsdflk.jar
            reference: STR_PARAM,CHOICE_PARAM
            omit-value: false
            choice-type: bullet-list

About

Enables support for Active Choice Plugin plugin in Jenkins Job Builder.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages