Giter VIP home page Giter VIP logo

jenkins-job-builder-active-choice's Introduction

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:

# OLD: partial support of Active Choice Plug-in capabilities
# deprecated -- see below
- job:
    name: 'cascade-choice-example'

    parameters:
      - string:
          name: STR_PARAM
          default: test
      - cascade-choice:
          project: 'cascade-choice-example'
          name: CASCADE_CHOICE
          script: |
            return ['foo:selected', 'bar']
          description: "A parameter named CASCADE_CHOICE which options foo and bar."
          visible-item-count: 1
          fallback-script: |
            return ['Something Wrong']
          reference: STR_PARAM
          choice-type: single
      - dynamic-reference:
          name: DYNAMIC_REF
          project: 'dynamic-reference-example-04'
          script: |
            return ['foo', 'bar']
          description: "A parameter named DYNAMIC_REF with options foo and bar."
          fallback-script: |
            return ['Something Wrong']
          reference: STR_PARAM
          omit-value: false
          choice-type: bullet-list

# 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

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.