Debian Codegraph @

lib/ansible/plugins/test/truthy.yml

raw
1 DOCUMENTATION:
2 name: truthy
3 author: Ansible Core
4 version_added: "2.10"
5 short_description: Pythonic true
6 description:
7 - This check is a more Python version of what is 'true'.
8 - It is the opposite of P(ansible.builtin.falsy#test).
9 options:
10 _input:
11 description: An expression that can be expressed in a boolean context.
12 type: string
13 required: True
14 convert_bool:
15 description: Attempts to convert to strict python boolean vs normally acceptable values (V(yes)/V(no), V(on)/V(off), V(0)/V(1), etc).
16 type: bool
17 default: false
18 EXAMPLES: |
19 thisistrue: '{{ "any string" is truthy }}'
20 thisisfalse: '{{ "" is truthy }}'
21 RETURN:
22 _value:
23 description: Returns V(True) if the condition is "Python truthy", V(False) otherwise.
24 type: boolean