GithubHelp home page GithubHelp logo

chonton / json-editor-parameter-plugin Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jenkinsci/json-editor-parameter-plugin

0.0 1.0 0.0 161 KB

Jenkins plugin adding json editor as a parameter provider

License: MIT License

Java 88.57% HTML 6.43% CSS 0.83% JavaScript 4.17%

json-editor-parameter-plugin's Introduction

json-editor-parameter

Introduction

Add parameters to an input step using the json-editor web form. The json editor generates an HTML form from a JSON Schema.

Getting started

There are two principal configuration parameters: schema, which contains the json schema of the input form; and startval, which contains the starting values of the form. An additional parameter options contains the lesser used parameters which configure the form. See options for additional information.

Pipeline Example

pipeline {
    agent any

    stages {
        stage('Hello') {
            steps {
                script {
                    def values= input message: 'an input test', parameters: [
                        jsonEditor(name: 'First', schema: '{"type":"object","title":"Car","properties":{"make":{"type":"string","enum":["Toyota","BMW","Honda","Ford","Chevy","VW"]},"model":{"type":"string"},"year":{"type":"integer","enum":[1995,1996,1997,1998,1999,2000,2001,2002,2003,2004,2005,2006,2007,2008,2009,2010,2011,2012,2013,2014],"default":2008},"safety":{"type":"integer","format":"rating","maximum":"5","exclusiveMaximum":false,"readonly":false}}}', startval: '{"make":"Toyota","safety":4}')
                    ]
                    println(values)
                }
            }
        }
    }
}

Issues

Report issues and request enhancements at the issues page.

Contributing

Pull requests are welcome!

Refer to Jenkins contribution guidelines for useful information.

License

Licensed under MIT, see LICENSE

json-editor-parameter-plugin's People

Contributors

chonton avatar dependabot[bot] avatar mawinter69 avatar

Watchers

 avatar

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.