From 079d00637e58871da6212147bcaa5498207c0fd9 Mon Sep 17 00:00:00 2001 From: Emmanuel Garette Date: Thu, 12 Mar 2026 08:10:58 +0100 Subject: [PATCH] [tutorial v1.1_120] Disabled a variable when an other variable are disabled (config and doc) --- README.md | 49 ++++++++++++++++++------------------------------- tree.html | 24 ++++++++++++------------ 2 files changed, 30 insertions(+), 43 deletions(-) diff --git a/README.md b/README.md index 2244bf51..cde7bfda 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,9 @@ - [Summary](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/branch/1.1/README.md) -- [[tutorial v1.1_111] A boolean variable](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_111/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_112~1..v1.1_112)) +- [[tutorial v1.1_112] A Jinja conditional disabled boolean variable](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_112/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_120~1..v1.1_120)) -# [tutorial v1.1_112] A Jinja conditional disabled boolean variable +# [tutorial v1.1_120] Disabled a variable when an other variable are disabled -[Read the tutorial "A Jinja conditional disabled boolean variable" in the documentation](https://pedago.gwenaelremond.fr/bribes/rougail/tutorial/jinja.html#a-jinja-conditional-disabled-boolean-variable) +[Read the tutorial "Disabled a variable when an other variable are disabled" in the documentation](https://pedago.gwenaelremond.fr/bribes/rougail/tutorial/jinja.html#disabled-a-variable-when-an-other-variable-are-disabled) ## Screenshot @@ -29,7 +29,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_112 +git switch --detach v1.1_120 ``` ## Structure @@ -37,18 +37,18 @@ git switch --detach v1.1_112

-.
- ├── firefox
- │   ├── 00-proxy.yml
- │   ├── 10-manual.yml
- │   ├── 20-manual.yml
- │   ├── 30-auto.yml
- │   ├── 40-no_proxy.yml
- │   ├── 50-prompt_authentication.yml
- │   └── 55-proxy_dns_socks5.yml
- └── types
-     └── proxy
-         └── 00_type.yml
+.
+ ├── firefox
+ │   ├── 00-proxy.yml
+ │   ├── 10-manual.yml
+ │   ├── 20-manual.yml
+ │   ├── 30-auto.yml
+ │   ├── 40-no_proxy.yml
+ │   ├── 50-prompt_authentication.yml
+ │   └── 55-proxy_dns_socks5.yml
+ └── types
+     └── proxy
+         └── 00_type.yml


Contents of the firefox/55-proxy_dns_socks5.yml file @@ -63,7 +63,7 @@ proxy_dns_socks5: default: false disabled: jinja: |- - {{ _.proxy_mode != "Manual proxy configuration" or _.manual.socks_proxy.version == 'v4' }} + {{ _.manual.socks_proxy.version is propertyerror or _.manual.socks_proxy.version == 'v4' }} return_type: boolean description: |- if "_.proxy_mode" is not "Manual proxy configuration" @@ -138,19 +138,6 @@ rougail -m firefox/ --types types/proxy -o doc | **proxy_dns_socks5**
[`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` *`disabled`* | Use proxy DNS when using SOCKS v5.
**Default**: false
**Disabled**: if "[Configure Proxy Access to the Internet](#proxy_mode)" is not "Manual proxy configuration"
or "[SOCKS host version used by proxy](#manual.socks_proxy.version)" is "v4" | -*** -### Let's generate the changelog - -```shell -rougail -m firefox/ --types types/proxy -o doc --doc.contents changelog --doc.changelog.previous_json_file previous.yml -``` -#### Modified variable - -| Variable | Description | -|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| **proxy_dns_socks5**
[`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` *`disabled`* | Use proxy DNS when using SOCKS v5.
**Default**: false
**Disabled**: if "[Configure Proxy Access to the Internet](#proxy_mode)" is not "Manual proxy configuration"
or "[SOCKS host version used by proxy](#manual.socks_proxy.version)" is "v4"
| - - *** ## User datas @@ -324,4 +311,4 @@ Variables: *** -- [[tutorial v1.1_120] Disabled a variable when an other variable are disabled](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_120/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_120~1..v1.1_120)) +- [[tutorial v1.1_130] A variable in avanced mode](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_130/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_130~1..v1.1_130)) diff --git a/tree.html b/tree.html index 317a06d9..586cf0f2 100644 --- a/tree.html +++ b/tree.html @@ -1,14 +1,14 @@

-.
- ├── firefox
- │   ├── 00-proxy.yml
- │   ├── 10-manual.yml
- │   ├── 20-manual.yml
- │   ├── 30-auto.yml
- │   ├── 40-no_proxy.yml
- │   ├── 50-prompt_authentication.yml
- │   └── 55-proxy_dns_socks5.yml
- └── types
-     └── proxy
-         └── 00_type.yml
+.
+ ├── firefox
+ │   ├── 00-proxy.yml
+ │   ├── 10-manual.yml
+ │   ├── 20-manual.yml
+ │   ├── 30-auto.yml
+ │   ├── 40-no_proxy.yml
+ │   ├── 50-prompt_authentication.yml
+ │   └── 55-proxy_dns_socks5.yml
+ └── types
+     └── proxy
+         └── 00_type.yml


\ No newline at end of file