Jenkins offers several different Input fields to enter values.
Textbox
Auto-completion
Start typing a US state for autocomplete results to appear.
Textboxes can feature auto-completion items by Stapler finds this method via the naming convention.
There is a similar control to the autocomplete functionality of "textbox" called combobox:
config.jelly:
SimpleCombobox.java:
Dynamic combobox
Like many other fields combo-boxes can be updated dynamically based on other field values:
config.jelly:
DynamicCombobox.java:
Number fields
Password fields
Textarea with syntax highlighting
CodeMirror can be used to turn an ordinary text area into a syntax-highlighted content-assistive text area.
You will want to use f:textarea
to pass more CodeMirror configuration if you are doing more than displaying a groovy text editor. There is support for many languages like groovy, xml, yaml, css, javascript, shell, python, perl
and many more.
Use the attribute codemirror-config
to specify additional key/value pairs in the JSON format (except the start and end bracket) to be passed as CodeMirror option object.
Shell
HTML
To edit html and have a preview you need the OWASP Markup Formatter plugin. Below snippet ensures that when the plugin is not installed that the preview will just print plain text.
Loading...