[tutorial v1.1_090)] A conditional disabled variable with type domainname and parameters (config and doc)
This commit is contained in:
parent
b3ac9763ea
commit
24e88d52f0
10 changed files with 52 additions and 71 deletions
78
README.md
78
README.md
|
|
@ -1,11 +1,11 @@
|
||||||
- [Summary](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/branch/1.1/README.md)
|
- [Summary](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/branch/1.1/README.md)
|
||||||
- [[tutorial v1.1_072] Jinja with a parameter](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_072/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_072~1..v1.1_072))
|
- [[tutorial v1.1_080] A conditional disabled variable with type web_address](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_080/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_080~1..v1.1_080))
|
||||||
|
|
||||||
# [tutorial v1.1_080)] A conditional disabled variable with type web_address
|
# [tutorial v1.1_090)] A conditional disabled variable with type domainname and parameters
|
||||||
|
|
||||||
[View the diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_080~1..v1.1_080)
|
[View the diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_090~1..v1.1_090)
|
||||||
|
|
||||||
[Read the documentation](https://pedago.gwenaelremond.fr/bribes/rougail/tutorial/calculation.html#a-conditional-disabled-variable-with-type-web_address)
|
[Read the documentation](https://pedago.gwenaelremond.fr/bribes/rougail/tutorial/calculation.html#a-conditional-disabled-variable-with-type-domainname-and-parameters)
|
||||||
|
|
||||||
|
|
||||||
## Screenshot
|
## Screenshot
|
||||||
|
|
@ -31,7 +31,7 @@ pip install rougail-cli rougail-output-exporter rougail-output-doc rougail-user-
|
||||||
Then switch to the tutorial page:
|
Then switch to the tutorial page:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
git switch --detach v1.1_080
|
git switch --detach v1.1_090
|
||||||
```
|
```
|
||||||
|
|
||||||
## Structure
|
## Structure
|
||||||
|
|
@ -39,27 +39,33 @@ git switch --detach v1.1_080
|
||||||
|
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
<a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_080/./">.</a><br/>
|
<a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./">.</a><br/>
|
||||||
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_080/./firefox/">firefox</a><br/>
|
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./firefox/">firefox</a><br/>
|
||||||
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_080/./firefox/00-proxy.yml">00-proxy.yml</a><br/>
|
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./firefox/00-proxy.yml">00-proxy.yml</a><br/>
|
||||||
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_080/./firefox/10-manual.yml">10-manual.yml</a><br/>
|
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./firefox/10-manual.yml">10-manual.yml</a><br/>
|
||||||
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_080/./firefox/20-manual.yml">20-manual.yml</a><br/>
|
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./firefox/20-manual.yml">20-manual.yml</a><br/>
|
||||||
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_080/./firefox/30-auto.yml">30-auto.yml</a><br/>
|
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./firefox/30-auto.yml">30-auto.yml</a><br/>
|
||||||
|
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./firefox/40-no_proxy.yml">40-no_proxy.yml</a><br/>
|
||||||
<br/><br/></p>
|
<br/><br/></p>
|
||||||
|
|
||||||
Contents of the firefox/30-auto.yml file
|
Contents of the firefox/40-no_proxy.yml file
|
||||||
|
|
||||||
```yml
|
```yml
|
||||||
%YAML 1.2
|
%YAML 1.2
|
||||||
---
|
---
|
||||||
version: 1.1
|
version: 1.1
|
||||||
|
|
||||||
auto:
|
no_proxy:
|
||||||
description: Automatic proxy configuration URL
|
description: Address for which proxy will be desactivated
|
||||||
type: web_address
|
type: domainname
|
||||||
|
params:
|
||||||
|
allow_ip: true
|
||||||
|
allow_cidr_network: true
|
||||||
|
allow_without_dot: true
|
||||||
|
allow_startswith_dot: true
|
||||||
disabled:
|
disabled:
|
||||||
variable: _.proxy_mode
|
variable: _.proxy_mode
|
||||||
when_not: Automatic proxy configuration URL
|
when: No proxy
|
||||||
...
|
...
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
@ -116,6 +122,7 @@ This family builds families dynamically
|
||||||
| Variable | Description |
|
| Variable | Description |
|
||||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||||
| **auto**<br/>[`web_address`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` *`disabled`* | Automatic proxy configuration URL.<br/>**Validator**: the domain name in web address can be only a hostname<br/>**Disabled**: when the variable "proxy_mode" hasn't the value "Automatic proxy configuration URL" |
|
| **auto**<br/>[`web_address`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` *`disabled`* | Automatic proxy configuration URL.<br/>**Validator**: the domain name in web address can be only a hostname<br/>**Disabled**: when the variable "proxy_mode" hasn't the value "Automatic proxy configuration URL" |
|
||||||
|
| **no_proxy**<br/>[`domainname`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` *`disabled`* | Address for which proxy will be desactivated.<br/>**Validators**: <br/>- the domain name can starts by a dot<br/>- the domain name can be a hostname<br/>- the domain name can be an IP<br/>- the domain name can be network in CIDR format<br/>**Disabled**: when the variable "proxy_mode" has the value "No proxy" |
|
||||||
|
|
||||||
### Let's generate the changelog
|
### Let's generate the changelog
|
||||||
|
|
||||||
|
|
@ -124,9 +131,9 @@ rougail -m firefox/ -o doc --doc.contents changelog
|
||||||
```
|
```
|
||||||
#### New variable
|
#### New variable
|
||||||
|
|
||||||
| Variable | Description |
|
| Variable | Description |
|
||||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||||
| **auto**<br/>[`web_address`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` *`disabled`* | Automatic proxy configuration URL.<br/>**Validator**: the domain name in web address can be only a hostname<br/>**Disabled**: when the variable "proxy_mode" hasn't the value "Automatic proxy configuration URL" |
|
| **no_proxy**<br/>[`domainname`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` *`disabled`* | Address for which proxy will be desactivated.<br/>**Validators**: <br/>- the domain name can starts by a dot<br/>- the domain name can be a hostname<br/>- the domain name can be an IP<br/>- the domain name can be network in CIDR format<br/>**Disabled**: when the variable "proxy_mode" has the value "No proxy" |
|
||||||
|
|
||||||
|
|
||||||
## User datas
|
## User datas
|
||||||
|
|
@ -138,16 +145,13 @@ rougail -m firefox/ -o doc --doc.contents changelog
|
||||||
|
|
||||||
```yml
|
```yml
|
||||||
---
|
---
|
||||||
auto: https://auto.proxy.net/wpad.dat
|
|
||||||
```
|
```
|
||||||
#### Output
|
#### Output
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
rougail -m firefox/ -u yaml -yf config/01/config.yml
|
rougail -m firefox/ -u yaml -yf config/01/config.yml
|
||||||
```
|
```
|
||||||
<pre><span style="font-weight: bold; color: #ffff00">🔔 WARNINGS</span>
|
<pre>╭─────── Caption ────────╮
|
||||||
<span style="color: #ffff00">┗━━ </span>variable "auto" (Automatic proxy configuration URL) is disabled, it will be ignored when loading from the YAML file "config/01/config.yml"
|
|
||||||
╭─────── Caption ────────╮
|
|
||||||
│ Variable <span style="color: #ffd700">Default value</span> │
|
│ Variable <span style="color: #ffd700">Default value</span> │
|
||||||
╰────────────────────────╯
|
╰────────────────────────╯
|
||||||
Variables:
|
Variables:
|
||||||
|
|
@ -161,39 +165,23 @@ Variables:
|
||||||
```yml
|
```yml
|
||||||
---
|
---
|
||||||
proxy_mode: Automatic proxy configuration URL
|
proxy_mode: Automatic proxy configuration URL
|
||||||
|
auto: https://auto.proxy.net/wpad.dat
|
||||||
|
no_proxy: 192.168.1.0/24
|
||||||
```
|
```
|
||||||
#### Output
|
#### Output
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
rougail -m firefox/ -u yaml -yf config/02/config.yml
|
rougail -m firefox/ -u yaml -yf config/02/config.yml
|
||||||
```
|
```
|
||||||
<pre><span style="font-weight: bold; color: #ff0000">🛑 ERRORS</span>
|
|
||||||
<span style="color: #ff0000">┗━━ </span>The following variables are mandatory but have no value:
|
|
||||||
<span style="color: #ff0000"> </span><span style="color: #ff0000">┗━━ </span>Automatic proxy configuration URL
|
|
||||||
</pre>
|
|
||||||
### Example 3
|
|
||||||
|
|
||||||
#### config/03/config.yml
|
|
||||||
|
|
||||||
|
|
||||||
```yml
|
|
||||||
---
|
|
||||||
proxy_mode: Automatic proxy configuration URL
|
|
||||||
auto: https://auto.proxy.net/wpad.dat
|
|
||||||
```
|
|
||||||
#### Output
|
|
||||||
|
|
||||||
```shell
|
|
||||||
rougail -m firefox/ -u yaml -yf config/03/config.yml
|
|
||||||
```
|
|
||||||
<pre>╭────────────── Caption ───────────────╮
|
<pre>╭────────────── Caption ───────────────╮
|
||||||
│ Variable Modified value │
|
│ Variable Modified value │
|
||||||
│ (<span style="color: #00aa00">⏳ Original default value</span>) │
|
│ (<span style="color: #00aa00">⏳ Original default value</span>) │
|
||||||
╰──────────────────────────────────────╯
|
╰──────────────────────────────────────╯
|
||||||
Variables:
|
Variables:
|
||||||
<span style="color: #5c5cff">┣━━ </span>📓 Configure Proxy Access to the Internet: Automatic proxy configuration URL ◀ loaded from the YAML file "config/03/config.yml" (⏳ <span style="color: #00aa00">No proxy</span>)
|
<span style="color: #5c5cff">┣━━ </span>📓 Configure Proxy Access to the Internet: Automatic proxy configuration URL ◀ loaded from the YAML file "config/02/config.yml" (⏳ <span style="color: #00aa00">No proxy</span>)
|
||||||
<span style="color: #5c5cff">┗━━ </span>📓 Automatic proxy configuration URL: https://auto.proxy.net/wpad.dat ◀ loaded from the YAML file "config/03/config.yml"
|
<span style="color: #5c5cff">┣━━ </span>📓 Automatic proxy configuration URL: https://auto.proxy.net/wpad.dat ◀ loaded from the YAML file "config/02/config.yml"
|
||||||
|
<span style="color: #5c5cff">┗━━ </span>📓 Address for which proxy will be desactivated: 192.168.1.0/24 ◀ loaded from the YAML file "config/02/config.yml"
|
||||||
</pre>
|
</pre>
|
||||||
|
|
||||||
|
|
||||||
- [[tutorial v1.1_090] A conditional disabled variable with type domainname and parameters](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_090~1..v1.1_090))
|
- [[tutorial v1.1_091] A variable with multiple value](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_091/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_091~1..v1.1_091))
|
||||||
|
|
|
||||||
|
|
@ -1,2 +1 @@
|
||||||
---
|
---
|
||||||
auto: https://auto.proxy.net/wpad.dat
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,4 @@
|
||||||
<pre><span style="font-weight: bold; color: #ffff00">🔔 WARNINGS</span>
|
<pre>╭─────── Caption ────────╮
|
||||||
<span style="color: #ffff00">┗━━ </span>variable "auto" (Automatic proxy configuration URL) is disabled, it will be ignored when loading from the YAML file "config/01/config.yml"
|
|
||||||
╭─────── Caption ────────╮
|
|
||||||
│ Variable <span style="color: #ffd700">Default value</span> │
|
│ Variable <span style="color: #ffd700">Default value</span> │
|
||||||
╰────────────────────────╯
|
╰────────────────────────╯
|
||||||
Variables:
|
Variables:
|
||||||
|
|
|
||||||
|
|
@ -1,2 +1,4 @@
|
||||||
---
|
---
|
||||||
proxy_mode: Automatic proxy configuration URL
|
proxy_mode: Automatic proxy configuration URL
|
||||||
|
auto: https://auto.proxy.net/wpad.dat
|
||||||
|
no_proxy: 192.168.1.0/24
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,9 @@
|
||||||
<pre><span style="font-weight: bold; color: #ff0000">🛑 ERRORS</span>
|
<pre>╭────────────── Caption ───────────────╮
|
||||||
<span style="color: #ff0000">┗━━ </span>The following variables are mandatory but have no value:
|
│ Variable Modified value │
|
||||||
<span style="color: #ff0000"> </span><span style="color: #ff0000">┗━━ </span>Automatic proxy configuration URL
|
│ (<span style="color: #00aa00">⏳ Original default value</span>) │
|
||||||
|
╰──────────────────────────────────────╯
|
||||||
|
Variables:
|
||||||
|
<span style="color: #5c5cff">┣━━ </span>📓 Configure Proxy Access to the Internet: Automatic proxy configuration URL ◀ loaded from the YAML file "config/02/config.yml" (⏳ <span style="color: #00aa00">No proxy</span>)
|
||||||
|
<span style="color: #5c5cff">┣━━ </span>📓 Automatic proxy configuration URL: https://auto.proxy.net/wpad.dat ◀ loaded from the YAML file "config/02/config.yml"
|
||||||
|
<span style="color: #5c5cff">┗━━ </span>📓 Address for which proxy will be desactivated: 192.168.1.0/24 ◀ loaded from the YAML file "config/02/config.yml"
|
||||||
</pre>
|
</pre>
|
||||||
|
|
|
||||||
|
|
@ -1 +0,0 @@
|
||||||
rougail -m firefox/ -u yaml -yf config/03/config.yml
|
|
||||||
|
|
@ -1,3 +0,0 @@
|
||||||
---
|
|
||||||
proxy_mode: Automatic proxy configuration URL
|
|
||||||
auto: https://auto.proxy.net/wpad.dat
|
|
||||||
|
|
@ -1,8 +0,0 @@
|
||||||
<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: Automatic proxy configuration URL ◀ loaded from the YAML file "config/03/config.yml" (⏳ <span style="color: #00aa00">No proxy</span>)
|
|
||||||
<span style="color: #5c5cff">┗━━ </span>📓 Automatic proxy configuration URL: https://auto.proxy.net/wpad.dat ◀ loaded from the YAML file "config/03/config.yml"
|
|
||||||
</pre>
|
|
||||||
BIN
firefox.png
BIN
firefox.png
Binary file not shown.
|
Before Width: | Height: | Size: 118 KiB After Width: | Height: | Size: 118 KiB |
15
tree.html
15
tree.html
|
|
@ -25,15 +25,16 @@
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<h1>Directory Tree</h1><p>
|
<h1>Directory Tree</h1><p>
|
||||||
<a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_080/./">.</a><br>
|
<a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./">.</a><br>
|
||||||
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_080/./firefox/">firefox</a><br>
|
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./firefox/">firefox</a><br>
|
||||||
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_080/./firefox/00-proxy.yml">00-proxy.yml</a><br>
|
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./firefox/00-proxy.yml">00-proxy.yml</a><br>
|
||||||
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_080/./firefox/10-manual.yml">10-manual.yml</a><br>
|
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./firefox/10-manual.yml">10-manual.yml</a><br>
|
||||||
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_080/./firefox/20-manual.yml">20-manual.yml</a><br>
|
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./firefox/20-manual.yml">20-manual.yml</a><br>
|
||||||
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_080/./firefox/30-auto.yml">30-auto.yml</a><br>
|
├── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./firefox/30-auto.yml">30-auto.yml</a><br>
|
||||||
|
└── <a href="https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_090/./firefox/40-no_proxy.yml">40-no_proxy.yml</a><br>
|
||||||
<br><br><p>
|
<br><br><p>
|
||||||
|
|
||||||
2 directories, 4 files
|
2 directories, 5 files
|
||||||
|
|
||||||
</p>
|
</p>
|
||||||
<hr>
|
<hr>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue