Skip to content

Commit 8871879

Browse files
committed
Add Az Pipeline quoted boolean docs
1 parent 93a1f40 commit 8871879

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed

docs/faq.rst

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,3 +81,37 @@ array with ``self-hosted``, like so:
8181
runs-on: [self-hosted, spot-self-hosted]
8282
steps:
8383
- run: echo 'hi'
84+
85+
Azure Pipelines Workflow
86+
------------------------
87+
88+
Quoted Boolean Issues
89+
~~~~~~~~~~~~~~~~~~~~~
90+
Microsoft's schema allows only for the strings ``"true"`` and ``"false"`` in a number
91+
of cases in which the booleans ``true`` and ``false`` should also be allowed.
92+
93+
For example, the following results in the validation error ``True is not of type 'string'``:
94+
95+
.. code-block:: yaml
96+
97+
parameters:
98+
- name: myBoolean
99+
displayName: myboolean
100+
type: boolean
101+
default: true
102+
103+
steps:
104+
- bash: echo "{{ parameters.myBoolean}}"
105+
106+
To resolve, quote the boolean:
107+
108+
.. code-block:: yaml
109+
110+
parameters:
111+
- name: myBoolean
112+
displayName: myboolean
113+
type: boolean
114+
default: 'true'
115+
116+
steps:
117+
- bash: echo "{{ parameters.myBoolean}}"

0 commit comments

Comments
 (0)