add a user data
This commit is contained in:
parent
aaeb18f199
commit
724b2bf60e
1 changed files with 39 additions and 4 deletions
|
|
@ -331,14 +331,14 @@ Let's insert these different possible choices with a `choice` variable's propert
|
||||||
|
|
||||||
:tutorial:`Download this file from the rougail-tutorials git repository <src/tag/v1.1_004/firefox/00-proxy.yml>`
|
:tutorial:`Download this file from the rougail-tutorials git repository <src/tag/v1.1_004/firefox/00-proxy.yml>`
|
||||||
|
|
||||||
- Let's run the Rougail CLI now:
|
- Let's run the Rougail CLI without user datas:
|
||||||
|
|
||||||
.. code-block:: text
|
.. code-block:: text
|
||||||
:class: terminal
|
:class: terminal
|
||||||
|
|
||||||
rougail -v 1.1 -m firefox/
|
rougail -v 1.1 -m firefox/
|
||||||
|
|
||||||
We have an output like this one:
|
We have this output:
|
||||||
|
|
||||||
.. raw:: html
|
.. raw:: html
|
||||||
:url: https://forge.cloud.silique.fr/stove/rougail-tutorials/raw/commit/v1.1_004/config/01/output_ro.html
|
:url: https://forge.cloud.silique.fr/stove/rougail-tutorials/raw/commit/v1.1_004/config/01/output_ro.html
|
||||||
|
|
@ -357,10 +357,45 @@ We have an output like this one:
|
||||||
|
|
||||||
The `proxy_mode` variable here, implicitely requires a value. It is a :term:`mandatory` variable.
|
The `proxy_mode` variable here, implicitely requires a value. It is a :term:`mandatory` variable.
|
||||||
|
|
||||||
As we set the `proxy_mode` variable as `No proxy` by default, we actually have specified a value,
|
As we set the `proxy_mode` variable as `No proxy` by default, we have specified a value,
|
||||||
and the value appears in yellow, which means : "set by default".
|
and the value appears in yellow, which means : "set by default".
|
||||||
|
|
||||||
.. todo:: ajouter une sortie qui montre que la valeur provient du user data file.
|
.. type-along:: Let's add a user value
|
||||||
|
|
||||||
|
Now an integrator decides to set the value of the `proxy_mode` variable to `Manual proxy configuration`.
|
||||||
|
|
||||||
|
.. extinclude:: https://forge.cloud.silique.fr/stove/rougail-tutorials/raw/tag/v1.1_004/config/03/config.yml
|
||||||
|
:linenos:
|
||||||
|
:language: yaml
|
||||||
|
:caption: A user data specification
|
||||||
|
|
||||||
|
:tutorial:`Download this file from the rougail-tutorials git repository <src/tag/v1.1_004/config/03/config.yml>`
|
||||||
|
|
||||||
|
If we run the rougail CLI with this user datas, we have:
|
||||||
|
|
||||||
|
.. code-block:: text
|
||||||
|
:class: terminal
|
||||||
|
|
||||||
|
rougail -m firefox -u yaml -ff config/03/config.yaml
|
||||||
|
|
||||||
|
We have this output:
|
||||||
|
|
||||||
|
.. raw:: html
|
||||||
|
:url: https://forge.cloud.silique.fr/stove/rougail-tutorials/raw/tag/v1.1_004/config/03/output_ro.html
|
||||||
|
:class: output
|
||||||
|
|
||||||
|
..
|
||||||
|
<pre>╭────────────── Caption ───────────────╮
|
||||||
|
│ Variable Modified value │
|
||||||
|
│ (<span style="color: #00aa00">⏳ Original default value</span>) │
|
||||||
|
╰──────────────────────────────────────╯
|
||||||
|
Variables:
|
||||||
|
<span style="color: #5c5cff">┗━━ </span>📓 Configure Proxy Access to the Internet: Manual proxy configuration ◀ loaded from the YAML file "config/03/config.yml" (⏳ <span style="color: #00aa00">No proxy</span>)
|
||||||
|
</pre>
|
||||||
|
|
||||||
|
As we set the `proxy_mode` variable from a user data file,
|
||||||
|
we now have specified a value which is **not** a default value,
|
||||||
|
and the value appears in green, which means : "user data value".
|
||||||
|
|
||||||
.. type-along:: The constraints that come with the `choice` property
|
.. type-along:: The constraints that come with the `choice` property
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue