[tutorial v1.1_003] Set a default value (config and doc)
This commit is contained in:
parent
632bc898c5
commit
42728482ea
7 changed files with 39 additions and 53 deletions
50
README.md
50
README.md
|
|
@ -1,11 +1,11 @@
|
|||
- [Summary](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/branch/1.1/README.md)
|
||||
- [[tutorial v1.1_001] Let’s add our first variable](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_001/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_001~1..v1.1_001))
|
||||
- [[tutorial v1.1_002] Describe the variable](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_002/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_002~1..v1.1_002))
|
||||
|
||||
# [tutorial v1.1_002] Describe the variable
|
||||
# [tutorial v1.1_003] Set a default value
|
||||
|
||||
[View the diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_002~1..v1.1_002)
|
||||
[View the diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_003~1..v1.1_003)
|
||||
|
||||
[Read the documentation](https://pedago.gwenaelremond.fr/bribes/rougail/tutorial/preliminary.html#describe-the-variable)
|
||||
[Read the documentation](https://pedago.gwenaelremond.fr/bribes/rougail/tutorial/preliminary.html#set-a-default-value)
|
||||
|
||||
|
||||
## Screenshot
|
||||
|
|
@ -31,7 +31,7 @@ pip install rougail-cli rougail-output-exporter rougail-output-doc rougail-user-
|
|||
Then switch to the tutorial page:
|
||||
|
||||
```shell
|
||||
git switch --detach v1.1_002
|
||||
git switch --detach v1.1_003
|
||||
```
|
||||
|
||||
## Structure
|
||||
|
|
@ -39,9 +39,9 @@ git switch --detach v1.1_002
|
|||
|
||||
|
||||
<p>
|
||||
<a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_002/./">.</a><br/>
|
||||
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_002/./firefox/">firefox</a><br/>
|
||||
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_002/./firefox/00-proxy.yml">00-proxy.yml</a><br/>
|
||||
<a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_003/./">.</a><br/>
|
||||
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_003/./firefox/">firefox</a><br/>
|
||||
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_003/./firefox/00-proxy.yml">00-proxy.yml</a><br/>
|
||||
<br/><br/></p>
|
||||
|
||||
Contents of the firefox/00-proxy.yml file
|
||||
|
|
@ -51,7 +51,7 @@ Contents of the firefox/00-proxy.yml file
|
|||
---
|
||||
version: 1.1
|
||||
|
||||
proxy_mode: # Configure Proxy Access to the Internet
|
||||
proxy_mode: No proxy # Configure Proxy Access to the Internet
|
||||
...
|
||||
|
||||
```
|
||||
|
|
@ -62,9 +62,9 @@ proxy_mode: # Configure Proxy Access to the Internet
|
|||
```shell
|
||||
rougail -m firefox/ -o doc
|
||||
```
|
||||
| Variable | Description |
|
||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------|
|
||||
| **<a id="proxy_mode" name="proxy_mode">proxy_mode</a>**<br/>[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | Configure Proxy Access to the Internet. |
|
||||
| Variable | Description |
|
||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------|
|
||||
| **<a id="proxy_mode" name="proxy_mode">proxy_mode</a>**<br/>[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | Configure Proxy Access to the Internet.<br/>**Default**: No proxy |
|
||||
|
||||
|
||||
***
|
||||
|
|
@ -75,9 +75,9 @@ rougail -m firefox/ -o doc --doc.contents changelog
|
|||
```
|
||||
#### Modified variable
|
||||
|
||||
| Variable | Description |
|
||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------|
|
||||
| **<a id="proxy_mode" name="proxy_mode">proxy_mode</a>**<br/>[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | <ins>Configure Proxy Access to the Internet.</ins> |
|
||||
| Variable | Description |
|
||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------|
|
||||
| **<a id="proxy_mode" name="proxy_mode">proxy_mode</a>**<br/>[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | Configure Proxy Access to the Internet.<br/>**Default**: <ins>No proxy</ins> |
|
||||
|
||||
|
||||
***
|
||||
|
|
@ -98,16 +98,6 @@ rougail -m firefox/ -o doc --doc.contents changelog
|
|||
```shell
|
||||
rougail -m firefox/ -u yaml -yf config/01/config.yml
|
||||
```
|
||||
> [!CAUTION]
|
||||
>
|
||||
> - proxy_mode (Configure Proxy Access to the Internet): :stop_sign: <span style="color: #C23636">mandatory variable but has no value</span>
|
||||
|
||||
***
|
||||
#### Output in read write mode
|
||||
|
||||
```shell
|
||||
rougail -m firefox/ -u yaml -yf config/01/config.yml --cli.read_write
|
||||
```
|
||||
> [!NOTE]
|
||||
>
|
||||
> **Caption:**
|
||||
|
|
@ -115,7 +105,7 @@ rougail -m firefox/ -u yaml -yf config/01/config.yml --cli.read_write
|
|||
> - <span style="color: #B8860B">Default value</span>
|
||||
|
||||
Variables:
|
||||
- :notebook: proxy_mode (Configure Proxy Access to the Internet): <span style="color: #B8860B">null</span>
|
||||
- :notebook: proxy_mode (Configure Proxy Access to the Internet): <span style="color: #B8860B">No proxy</span>
|
||||
|
||||
***
|
||||
### Example 2
|
||||
|
|
@ -139,9 +129,10 @@ rougail -m firefox/ -u yaml -yf config/02/config.yml
|
|||
> **Caption:**
|
||||
> - Variable
|
||||
> - <span style="color: #006400">Modified value</span>
|
||||
> - (:hourglass_flowing_sand: Original default value)
|
||||
|
||||
Variables:
|
||||
- :notebook: proxy_mode (Configure Proxy Access to the Internet): <span style="color: #006400">No proxy</span> ← loaded from the YAML file "config/02/config.yml"
|
||||
- :notebook: proxy_mode (Configure Proxy Access to the Internet): <span style="color: #006400">No proxy</span> ← loaded from the YAML file "config/02/config.yml" (:hourglass_flowing_sand: No proxy)
|
||||
|
||||
***
|
||||
### Example 3
|
||||
|
|
@ -165,11 +156,12 @@ rougail -m firefox/ -u yaml -yf config/03/config.yml
|
|||
> **Caption:**
|
||||
> - Variable
|
||||
> - <span style="color: #006400">Modified value</span>
|
||||
> - (:hourglass_flowing_sand: Original default value)
|
||||
|
||||
Variables:
|
||||
- :notebook: proxy_mode (Configure Proxy Access to the Internet): <span style="color: #006400">foo</span> ← loaded from the YAML file "config/03/config.yml"
|
||||
- :notebook: proxy_mode (Configure Proxy Access to the Internet): <span style="color: #006400">foo</span> ← loaded from the YAML file "config/03/config.yml" (:hourglass_flowing_sand: No proxy)
|
||||
|
||||
***
|
||||
|
||||
|
||||
- [[tutorial v1.1_003] Set a default value](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_003/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_003~1..v1.1_003))
|
||||
- [[tutorial v1.1_010] A variable with a list of possible values](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_010/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_010~1..v1.1_010))
|
||||
|
|
|
|||
|
|
@ -1 +0,0 @@
|
|||
rougail -m firefox/ -u yaml -yf config/01/config.yml --cli.read_write
|
||||
|
|
@ -1,4 +1,6 @@
|
|||
<pre><span style="font-weight: bold; color: #ff0000">🛑 Caution</span>
|
||||
<span style="color: #ff0000">┗━━ </span>proxy_mode (Configure Proxy Access to the Internet): <span style="color: #ff0000">🛑 mandatory variable </span>
|
||||
<span style="color: #ff0000"> </span><span style="color: #ff0000">but has no value</span>
|
||||
<pre>╭─────── Caption ────────╮
|
||||
│ Variable <span style="color: #ffd700">Default value</span> │
|
||||
╰────────────────────────╯
|
||||
Variables:
|
||||
<span style="color: #5c5cff">┗━━ </span>📓 proxy_mode (Configure Proxy Access to the Internet): <span style="color: #ffd700">No proxy</span>
|
||||
</pre>
|
||||
|
|
|
|||
|
|
@ -1,9 +0,0 @@
|
|||
<pre>> [!NOTE]
|
||||
>
|
||||
> **Caption:**
|
||||
> - Variable
|
||||
> - <span style="color: #B8860B">Default value</span>
|
||||
|
||||
Variables:
|
||||
- :notebook: proxy_mode (Configure Proxy Access to the Internet): <span style="color: #B8860B">null</span>
|
||||
</pre>
|
||||
|
|
@ -1,7 +1,8 @@
|
|||
<pre>╭──────── Caption ────────╮
|
||||
│ Variable <span style="color: #00aa00">Modified value</span> │
|
||||
╰─────────────────────────╯
|
||||
<pre>╭────────────── Caption ───────────────╮
|
||||
│ Variable <span style="color: #00aa00">Modified value</span> │
|
||||
│ (⏳ Original default value) │
|
||||
╰──────────────────────────────────────╯
|
||||
Variables:
|
||||
<span style="color: #5c5cff">┗━━ </span>📓 proxy_mode (Configure Proxy Access to the Internet): <span style="color: #00aa00">No proxy</span> ◀ loaded
|
||||
<span style="color: #5c5cff"> </span>from the YAML file "config/02/config.yml"
|
||||
<span style="color: #5c5cff"> </span>from the YAML file "config/02/config.yml" (⏳ No proxy)
|
||||
</pre>
|
||||
|
|
|
|||
|
|
@ -1,7 +1,8 @@
|
|||
<pre>╭──────── Caption ────────╮
|
||||
│ Variable <span style="color: #00aa00">Modified value</span> │
|
||||
╰─────────────────────────╯
|
||||
<pre>╭────────────── Caption ───────────────╮
|
||||
│ Variable <span style="color: #00aa00">Modified value</span> │
|
||||
│ (⏳ Original default value) │
|
||||
╰──────────────────────────────────────╯
|
||||
Variables:
|
||||
<span style="color: #5c5cff">┗━━ </span>📓 proxy_mode (Configure Proxy Access to the Internet): <span style="color: #00aa00">foo</span> ◀ loaded from
|
||||
<span style="color: #5c5cff"> </span>the YAML file "config/03/config.yml"
|
||||
<span style="color: #5c5cff"> </span>the YAML file "config/03/config.yml" (⏳ No proxy)
|
||||
</pre>
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
<p>
|
||||
<a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_002/./">.</a><br/>
|
||||
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_002/./firefox/">firefox</a><br/>
|
||||
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_002/./firefox/00-proxy.yml">00-proxy.yml</a><br/>
|
||||
<a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_003/./">.</a><br/>
|
||||
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_003/./firefox/">firefox</a><br/>
|
||||
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_003/./firefox/00-proxy.yml">00-proxy.yml</a><br/>
|
||||
<br/><br/></p>
|
||||
Loading…
Reference in a new issue