4
0

input_checkbox.adoc 635 B

1234567891011121314151617181920212223
  1. [#confirmation]
  2. = Input: Checkbox/Boolean
  3. The `checkbox` type argument is a simple checkbox that can be used to toggle a boolean value. It can be especially useful to pass flags to your actions.
  4. Define `choices` for the checked/unchecked values. A checkbox **without** choices is not allowed with `shell:` (use `exec:` instead).
  5. [source,yaml]
  6. ----
  7. actions:
  8. - title: remove files
  9. shell: rm {{ useTheForce }} /tmp/Downloads/
  10. arguments:
  11. - title: Use rm -rf?
  12. name: useTheForce
  13. type: checkbox
  14. choices:
  15. - title: 1
  16. value: "-rf"
  17. - title: 0
  18. value: ""
  19. ----