[tutorial 051] A conditional disabled variable (config and doc)
This commit is contained in:
parent
79694388ee
commit
7443c4bf1c
2 changed files with 33 additions and 28 deletions
54
README.md
54
README.md
|
@ -1,9 +1,9 @@
|
||||||
- [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 041] Variable: "shorthand" mode](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_041/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_041~1..v1.1_041))
|
- [[tutorial 050] A variable with type "web_address"](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_050/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_050~1..v1.1_050))
|
||||||
|
|
||||||
# [tutorial 050] A variable with type "web_address"
|
# [tutorial 051] A conditional disabled variable
|
||||||
|
|
||||||
[View the diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_050~1..v1.1_050)
|
[View the diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_051~1..v1.1_051)
|
||||||
|
|
||||||
|
|
||||||
## Screenshot
|
## Screenshot
|
||||||
|
@ -110,6 +110,9 @@ manual:
|
||||||
auto:
|
auto:
|
||||||
description: Automatic proxy configuration URL
|
description: Automatic proxy configuration URL
|
||||||
type: web_address
|
type: web_address
|
||||||
|
disabled:
|
||||||
|
variable: proxy_mode
|
||||||
|
when_not: Automatic proxy configuration URL
|
||||||
|
|
||||||
```
|
```
|
||||||
### Generated documentation
|
### Generated documentation
|
||||||
|
@ -119,9 +122,9 @@ foo@bar:~$ rougail -v 1.1 -m firefox/ -o doc -do github
|
||||||
```
|
```
|
||||||
### Variables
|
### Variables
|
||||||
|
|
||||||
| Variable | Description |
|
| Variable | Description |
|
||||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||||
| **proxy_mode**<br/>[`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | Configure Proxy Access to the Internet.<br/>**Choices**: <br/>- No proxy ← (default)<br/>- Auto-detect proxy settings for this network<br/>- Use system proxy settings<br/>- Manual proxy configuration<br/>- Automatic proxy configuration URL |
|
| **proxy_mode**<br/>[`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | Configure Proxy Access to the Internet.<br/>**Choices**: <br/>- No proxy ← (default)<br/>- Auto-detect proxy settings for this network<br/>- Use system proxy settings<br/>- Manual proxy configuration<br/>- Automatic proxy configuration URL |
|
||||||
|
|
||||||
#### Manual proxy configuration
|
#### Manual proxy configuration
|
||||||
|
|
||||||
|
@ -131,14 +134,14 @@ _`disabled`_
|
||||||
|
|
||||||
##### HTTP Proxy
|
##### HTTP Proxy
|
||||||
|
|
||||||
| Variable | Description |
|
| Variable | Description |
|
||||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||||
| **manual.http_proxy.address**<br/>[`domainname`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | HTTP address.<br/>**Validator**: the domain name can be an IP |
|
| **manual.http_proxy.address**<br/>[`domainname`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | HTTP address.<br/>**Validator**: the domain name can be an IP |
|
||||||
| **manual.http_proxy.port**<br/>[`port`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | HTTP Port.<br/>**Default**: 8080 |
|
| **manual.http_proxy.port**<br/>[`port`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | HTTP Port.<br/>**Default**: 8080 |
|
||||||
|
|
||||||
| Variable | Description |
|
| Variable | Description |
|
||||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||||
| **manual.use_for_https**<br/>[`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | Also use this proxy for HTTPS.<br/>**Default**: True |
|
| **manual.use_for_https**<br/>[`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | Also use this proxy for HTTPS.<br/>**Default**: True |
|
||||||
|
|
||||||
##### "*HTTPS* Proxy" or "*SOCKS* Proxy"
|
##### "*HTTPS* Proxy" or "*SOCKS* Proxy"
|
||||||
|
|
||||||
|
@ -151,15 +154,15 @@ This family builds families dynamically.
|
||||||
|
|
||||||
**Identifiers**: <br/>- HTTPS<br/>- SOCKS
|
**Identifiers**: <br/>- HTTPS<br/>- SOCKS
|
||||||
|
|
||||||
| Variable | Description |
|
| Variable | Description |
|
||||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||||
| **manual.https_proxy.address** or **manual.socks_proxy.address**<br/>[`domainname`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | "*HTTPS* address" or "*SOCKS* address".<br/>**Validator**: the domain name can be an IP<br/>**Default**: the value of the variable "manual.http_proxy.address". |
|
| **manual.https_proxy.address** or **manual.socks_proxy.address**<br/>[`domainname`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | "*HTTPS* address" or "*SOCKS* address".<br/>**Validator**: the domain name can be an IP<br/>**Default**: the value of the variable "manual.http_proxy.address". |
|
||||||
| **manual.https_proxy.port** or **manual.socks_proxy.port**<br/>[`port`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | "*HTTPS* port" or "*SOCKS* port".<br/>**Default**: the value of the variable "manual.http_proxy.port". |
|
| **manual.https_proxy.port** or **manual.socks_proxy.port**<br/>[`port`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | "*HTTPS* port" or "*SOCKS* port".<br/>**Default**: the value of the variable "manual.http_proxy.port". |
|
||||||
| **manual.https_proxy.version** or **manual.socks_proxy.version**<br/>[`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` _`disabled`_ | SOCKS host version used by proxy.<br/>**Choices**: <br/>- v4<br/>- v5 ← (default)<br/>**Disabled**: when the identifier is "HTTPS". |
|
| **manual.https_proxy.version** or **manual.socks_proxy.version**<br/>[`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` _`disabled`_ | SOCKS host version used by proxy.<br/>**Choices**: <br/>- v4<br/>- v5 ← (default)<br/>**Disabled**: when the identifier is "HTTPS". |
|
||||||
|
|
||||||
| Variable | Description |
|
| Variable | Description |
|
||||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||||
| **auto**<br/>[`web_address`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | 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/>**Disabled**: proxy_mode. |
|
||||||
|
|
||||||
|
|
||||||
## User data
|
## User data
|
||||||
|
@ -179,15 +182,16 @@ auto: https://auto.proxy.net/wpad.dat
|
||||||
```console
|
```console
|
||||||
foo@bar:~$ rougail -v 1.1 -m firefox/ -u file -ff config/01/config.yaml
|
foo@bar:~$ rougail -v 1.1 -m firefox/ -u file -ff config/01/config.yaml
|
||||||
```
|
```
|
||||||
<pre>╭────────────────────────── Caption ──────────────────────────╮
|
<pre>🛑 ERRORS
|
||||||
|
<span style="color: #ff0000">┗━━ </span>cannot access to option "auto" (Automatic proxy configuration URL) because has property "disabled"
|
||||||
|
╭────────────────────────── Caption ──────────────────────────╮
|
||||||
│ Variable <span style="color: #ffd700">Default value</span> │
|
│ Variable <span style="color: #ffd700">Default value</span> │
|
||||||
│ <span style="color: #5c5cff">Undocumented variable</span> Modified value │
|
│ <span style="color: #5c5cff">Undocumented variable</span> Modified value │
|
||||||
│ <span style="color: #ff0000">Undocumented but modified variable</span> (<span style="color: #00aa00">Original default value</span>) │
|
│ <span style="color: #ff0000">Undocumented but modified variable</span> (<span style="color: #00aa00">Original default value</span>) │
|
||||||
│ <span style="color: #ffaf00">Unmodifiable variable</span> │
|
│ <span style="color: #ffaf00">Unmodifiable variable</span> │
|
||||||
╰─────────────────────────────────────────────────────────────╯
|
╰─────────────────────────────────────────────────────────────╯
|
||||||
Variables:
|
Variables:
|
||||||
<span style="color: #5c5cff">┣━━ </span>📓 proxy_mode: <span style="color: #ffd700">No proxy</span>
|
<span style="color: #5c5cff">┗━━ </span>📓 proxy_mode: <span style="color: #ffd700">No proxy</span>
|
||||||
<span style="color: #5c5cff">┗━━ </span>📓 auto: https://auto.proxy.net/wpad.dat
|
|
||||||
</pre>
|
</pre>
|
||||||
### Example 2
|
### Example 2
|
||||||
|
|
||||||
|
@ -236,4 +240,4 @@ Variables:
|
||||||
</pre>
|
</pre>
|
||||||
|
|
||||||
|
|
||||||
- [[tutorial 051] A conditional disabled variable](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_051/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_051~1..v1.1_051))
|
- [[tutorial 060] A variable with type "domainname", parameters type and disabled](https://forge.cloud.silique.fr/stove/rougail-tutorials/src/commit/v1.1_060/README.md) ([diff](https://forge.cloud.silique.fr/stove/rougail-tutorials/compare/v1.1_060~1..v1.1_060))
|
||||||
|
|
|
@ -1,10 +1,11 @@
|
||||||
<pre>╭────────────────────────── Caption ──────────────────────────╮
|
<pre>🛑 ERRORS
|
||||||
|
<span style="color: #ff0000">┗━━ </span>cannot access to option "auto" (Automatic proxy configuration URL) because has property "disabled"
|
||||||
|
╭────────────────────────── Caption ──────────────────────────╮
|
||||||
│ Variable <span style="color: #ffd700">Default value</span> │
|
│ Variable <span style="color: #ffd700">Default value</span> │
|
||||||
│ <span style="color: #5c5cff">Undocumented variable</span> Modified value │
|
│ <span style="color: #5c5cff">Undocumented variable</span> Modified value │
|
||||||
│ <span style="color: #ff0000">Undocumented but modified variable</span> (<span style="color: #00aa00">Original default value</span>) │
|
│ <span style="color: #ff0000">Undocumented but modified variable</span> (<span style="color: #00aa00">Original default value</span>) │
|
||||||
│ <span style="color: #ffaf00">Unmodifiable variable</span> │
|
│ <span style="color: #ffaf00">Unmodifiable variable</span> │
|
||||||
╰─────────────────────────────────────────────────────────────╯
|
╰─────────────────────────────────────────────────────────────╯
|
||||||
Variables:
|
Variables:
|
||||||
<span style="color: #5c5cff">┣━━ </span>📓 proxy_mode: <span style="color: #ffd700">No proxy</span>
|
<span style="color: #5c5cff">┗━━ </span>📓 proxy_mode: <span style="color: #ffd700">No proxy</span>
|
||||||
<span style="color: #5c5cff">┗━━ </span>📓 auto: https://auto.proxy.net/wpad.dat
|
|
||||||
</pre>
|
</pre>
|
||||||
|
|
Loading…
Reference in a new issue