fix: documentation

This commit is contained in:
egarette@silique.fr 2025-12-22 15:32:21 +01:00
parent 3ad2b9a587
commit 7d8bfa87fd
7 changed files with 208 additions and 26 deletions

27
README.fr.md Normal file
View file

@ -0,0 +1,27 @@
---
gitea: none
include_toc: true
---
[🇬🇧 (EN)](README.md) - [🇫🇷 (FR)](README.fr.md)
## Options de la ligne de commande
> [!NOTE]
>
> **Chemin** : cli
| Variable | Description | Valeur par défaut | Type | Contrôle des accès | Validateur |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------|------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------|
| **<a id="cli.config_file" name="cli.config_file">cli.config_file</a>**<br/>**Variable d'environnement** : CLI.CONFIG_FILE | Charger les paramètres de la ligne de commande depuis un fichier. | •&nbsp;.rougailcli.yml | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | | •&nbsp;le nom de fichier peut être une chemin relatif<br/>&nbsp;type de fichier autorisé: "fichier" et "répertoire". |
| **<a id="cli.debug" name="cli.debug">cli.debug</a>**<br/>**Ligne de commande** : <br/>&nbsp;--cli.debug<br/>&nbsp;--cli.no-debug<br/>**Variable d'environnement** : CLI.DEBUG | Afficher les informations de debug. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | | |
| **<a id="cli.warnings" name="cli.warnings">cli.warnings</a>**<br/>**Ligne de commande** : <br/>&nbsp;--cli.warnings<br/>&nbsp;--cli.no-warnings<br/>**Variable d'environnement** : CLI.WARNINGS | Afficher les avertissements de chargement des options de la ligne de commande. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | | |
| **<a id="cli.versions" name="cli.versions">cli.versions</a>**<br/>**Ligne de commande** : <br/>&nbsp;--cli.versions<br/>&nbsp;--cli.no-versions<br/>**Variable d'environnement** : CLI.VERSIONS | Afficher la version de Rougail et de tous ces composants. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | | |
| **<a id="cli.invalid_user_data_error" name="cli.invalid_user_data_error">cli.invalid_user_data_error</a>**<br/>**Ligne de commande** : <br/>&nbsp;--cli.invalid_user_data_error<br/>&nbsp;--cli.no-invalid_user_data_error<br/>**Variable d'environnement** : CLI.INVALID_USER_DATA_ERROR | Les valeurs invalides dans les données utilisateur ne sont pas autorisées. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | | |
| **<a id="cli.unknown_user_data_error" name="cli.unknown_user_data_error">cli.unknown_user_data_error</a>**<br/>**Ligne de commande** : <br/>&nbsp;--cli.unknown_user_data_error<br/>&nbsp;--cli.no-unknown_user_data_error<br/>**Variable d'environnement** : CLI.UNKNOWN_USER_DATA_ERROR | Les variables inconnues dans les données utilisateur ne sont pas autorisées. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | | |
| **<a id="cli.layers" name="cli.layers">cli.layers</a>**<br/>**Ligne de commande** : <br/>&nbsp;--cli.layers<br/>&nbsp;--cli.no-layers<br/>**Variable d'environnement** : CLI.LAYERS | Charger chaque données utilisateurs dans des couches séparées. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | *`cachée`*<br/>**Cachée** : si seulement un type de données utilisateur est renseigné dans "[Sélection pour données utilisateur](#step.user_data)" | |
| **<a id="cli.read_write" name="cli.read_write">cli.read_write</a>**<br/>**Ligne de commande** : <br/>&nbsp;--cli.read_write<br/>&nbsp;--cli.no-read_write<br/>**Variable d'environnement** : CLI.READ_WRITE | La configuration dans l&#x27;état de sortie est dans mode lecture-écriture. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | | |
| **<a id="cli.description_type" name="cli.description_type">cli.description_type</a>**<br/>**Ligne de commande** : --cli.description_type<br/>**Variable d'environnement** : CLI.DESCRIPTION_TYPE | Type de description des variables.<br/>Pour identifier les différentes variables, on utilise la description de la variable. Il y a quatre type de descriptions:<br/>- name_and_description : qui contient le nom de la variable suivi de sa description - path : le chemin de la variable - name : le nom de la variable - description : la description de la variable. | description | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | | **Choix** : <br/>&nbsp;name_and_description<br/>&nbsp;path<br/>&nbsp;name<br/>&nbsp;description |
| **<a id="cli.inaccessible_read_write_modes" name="cli.inaccessible_read_write_modes">cli.inaccessible_read_write_modes</a>**<br/>**Ligne de commande** : --cli.inaccessible_read_write_modes<br/>**Variable d'environnement** : CLI.INACCESSIBLE_READ_WRITE_MODES | Modes quoi doivent être inaccessible en mode lecture-écriture. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | *`désactivé`*<br/>**Désactivé** : si aucun mode n'est défini dans "[Tous les niveaux de modes valides](#modes_level)" | `unique`<br/>Un mode doit exister dans "[Tous les niveaux de modes valides](#modes_level)". |
| **<a id="cli.inaccessible_modes" name="cli.inaccessible_modes">cli.inaccessible_modes</a>**<br/>**Ligne de commande** : --cli.inaccessible_modes<br/>**Variable d'environnement** : CLI.INACCESSIBLE_MODES | Modes quoi doivent être inaccessible. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | *`désactivé`*<br/>**Désactivé** : si aucun mode n'est défini dans "[Tous les niveaux de modes valides](#modes_level)" | `unique`<br/>Un mode doit exister dans "[Tous les niveaux de modes valides](#modes_level)". |

View file

@ -1,2 +1,27 @@
# rougail-cli ---
gitea: none
include_toc: true
---
[🇬🇧 (EN)](README.md) - [🇫🇷 (FR)](README.fr.md)
## Command line options
> [!NOTE]
>
> **Path**: cli
| Variable | Description | Default value | Type | Access control | Validator |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------|------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------|
| **<a id="cli.config_file" name="cli.config_file">cli.config_file</a>**<br/>**Environment variable**: CLI.CONFIG_FILE | Loads command line parameters from a file. | •&nbsp;.rougailcli.yml | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | | •&nbsp;this filename could be a relative path<br/>&nbsp;file type allowed: "directory" and "file". |
| **<a id="cli.debug" name="cli.debug">cli.debug</a>**<br/>**Command line**: <br/>&nbsp;--cli.debug<br/>&nbsp;--cli.no-debug<br/>**Environment variable**: CLI.DEBUG | Displays debug informations. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | | |
| **<a id="cli.warnings" name="cli.warnings">cli.warnings</a>**<br/>**Command line**: <br/>&nbsp;--cli.warnings<br/>&nbsp;--cli.no-warnings<br/>**Environment variable**: CLI.WARNINGS | Displays command line option warnings informations. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | | |
| **<a id="cli.versions" name="cli.versions">cli.versions</a>**<br/>**Command line**: <br/>&nbsp;--cli.versions<br/>&nbsp;--cli.no-versions<br/>**Environment variable**: CLI.VERSIONS | Displays Rougail version and all its components. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | | |
| **<a id="cli.invalid_user_data_error" name="cli.invalid_user_data_error">cli.invalid_user_data_error</a>**<br/>**Command line**: <br/>&nbsp;--cli.invalid_user_data_error<br/>&nbsp;--cli.no-invalid_user_data_error<br/>**Environment variable**: CLI.INVALID_USER_DATA_ERROR | Invalid value in user data is not allowed. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | | |
| **<a id="cli.unknown_user_data_error" name="cli.unknown_user_data_error">cli.unknown_user_data_error</a>**<br/>**Command line**: <br/>&nbsp;--cli.unknown_user_data_error<br/>&nbsp;--cli.no-unknown_user_data_error<br/>**Environment variable**: CLI.UNKNOWN_USER_DATA_ERROR | Unknown variable in user data is not allowed. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | | |
| **<a id="cli.layers" name="cli.layers">cli.layers</a>**<br/>**Command line**: <br/>&nbsp;--cli.layers<br/>&nbsp;--cli.no-layers<br/>**Environment variable**: CLI.LAYERS | Open each user data in separate layers. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | *`hidden`*<br/>**Hidden**: if only one user data is set in "[Select for user datas](#step.user_data)" | |
| **<a id="cli.read_write" name="cli.read_write">cli.read_write</a>**<br/>**Command line**: <br/>&nbsp;--cli.read_write<br/>&nbsp;--cli.no-read_write<br/>**Environment variable**: CLI.READ_WRITE | Configuration in output step is in read_write mode. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | | |
| **<a id="cli.description_type" name="cli.description_type">cli.description_type</a>**<br/>**Command line**: --cli.description_type<br/>**Environment variable**: CLI.DESCRIPTION_TYPE | Type of variables description.<br/>To identify different variables, we use the variable description. There are four types of description:<br/>- name_and_description: which contains the variable name followed by its description - path: the variable&#x27;s path - name: the variable name - description: the variable&#x27;s description. | description | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | | **Choices**: <br/>&nbsp;name_and_description<br/>&nbsp;path<br/>&nbsp;name<br/>&nbsp;description |
| **<a id="cli.inaccessible_read_write_modes" name="cli.inaccessible_read_write_modes">cli.inaccessible_read_write_modes</a>**<br/>**Command line**: --cli.inaccessible_read_write_modes<br/>**Environment variable**: CLI.INACCESSIBLE_READ_WRITE_MODES | Modes that should not be accessible in read_write mode. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | *`disabled`*<br/>**Disabled**: if any mode is set in "[All modes level available](#modes_level)" | `unique`<br/>Mode must exists in "[All modes level available](#modes_level)". |
| **<a id="cli.inaccessible_modes" name="cli.inaccessible_modes">cli.inaccessible_modes</a>**<br/>**Command line**: --cli.inaccessible_modes<br/>**Environment variable**: CLI.INACCESSIBLE_MODES | Modes that should not be accessible. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | *`disabled`*<br/>**Disabled**: if any mode is set in "[All modes level available](#modes_level)" | `unique`<br/>Mode must exists in "[All modes level available](#modes_level)". |

View file

@ -5,8 +5,8 @@
msgid "" msgid ""
msgstr "" msgstr ""
"Project-Id-Version: \n" "Project-Id-Version: \n"
"POT-Creation-Date: 2025-05-14 08:22+0200\n" "POT-Creation-Date: 2025-12-22 15:24+0100\n"
"PO-Revision-Date: 2025-05-14 08:22+0200\n" "PO-Revision-Date: 2025-12-22 15:28+0100\n"
"Last-Translator: \n" "Last-Translator: \n"
"Language-Team: \n" "Language-Team: \n"
"Language: fr\n" "Language: fr\n"
@ -14,17 +14,25 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n" "Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n" "Content-Transfer-Encoding: 8bit\n"
"Generated-By: pygettext.py 1.5\n" "Generated-By: pygettext.py 1.5\n"
"X-Generator: Poedit 3.5\n" "X-Generator: Poedit 3.8\n"
#: src/rougail/cli/__main__.py:170 #: src/rougail/cli/__main__.py:237
msgid "cannot find \"user_data\" module \"{0}\"" msgid "cannot find \"user_data\" module \"{0}\""
msgstr "ne peut trouve le module \"user_data\" \"{0}\"" msgstr "ne peut trouve le module \"user_data\" \"{0}\""
#: src/rougail/cli/__main__.py:214 #: src/rougail/cli/__main__.py:245
msgid ""
"interactive user data \"{0}\" is loader before uninteractive user data "
"\"{1}\""
msgstr ""
"Les données utilisateur interactifs \"{0}\" sont chargées avant les données "
"utilisateur non interactif \"{1}\""
#: src/rougail/cli/__main__.py:281
msgid "cannot find cli file for \"output_name\" module \"{0}\"" msgid "cannot find cli file for \"output_name\" module \"{0}\""
msgstr "ne peut trouve le fichier cli pour le module \"output_name\" \"{0}\"" msgstr "ne peut trouve le fichier cli pour le module \"output_name\" \"{0}\""
#: src/rougail/cli/__main__.py:240 #: src/rougail/cli/__main__.py:306
msgid "ERROR: {0}" msgid "ERROR: {0}"
msgstr "ERREUR : {0}" msgstr "ERREUR : {0}"
@ -40,14 +48,79 @@ msgstr "Charger les paramètres de la ligne de commande depuis un fichier"
msgid "Displays debug informations" msgid "Displays debug informations"
msgstr "Afficher les informations de debug" msgstr "Afficher les informations de debug"
#: src/rougail/cli/config.py:43 #: src/rougail/cli/config.py:41
msgid "Displays command line option warnings informations" msgid "Displays command line option warnings informations"
msgstr "Afficher les avertissements de chargement des options de la ligne de commande" msgstr ""
"Afficher les avertissements de chargement des options de la ligne de commande"
#: src/rougail/cli/config.py:47 #: src/rougail/cli/config.py:43
msgid "Displays Rougail version and all its components" msgid "Displays Rougail version and all its components"
msgstr "Afficher la version de Rougail et de tous ces composants" msgstr "Afficher la version de Rougail et de tous ces composants"
#: src/rougail/cli/config.py:45
msgid "Invalid value in user data is not allowed"
msgstr ""
"Les valeurs invalides dans les données utilisateur ne sont pas autorisées"
#: src/rougail/cli/config.py:47
msgid "Unknown variable in user data is not allowed"
msgstr ""
"Les variables inconnues dans les données utilisateur ne sont pas autorisées"
#: src/rougail/cli/config.py:50
msgid "Open each user data in separate layers"
msgstr "Charger chaque données utilisateurs dans des couches séparées"
#: src/rougail/cli/config.py:56
msgid "if only one user data is set in \"__.step.user_data\""
msgstr ""
"si seulement un type de données utilisateur est renseigné dans "
"\"__.step.user_data\""
#: src/rougail/cli/config.py:62
msgid "Configuration in output step is in read_write mode"
msgstr "La configuration dans l'état de sortie est dans mode lecture-écriture"
#: src/rougail/cli/config.py:65
msgid "Type of variables description"
msgstr "Type de description des variables"
#: src/rougail/cli/config.py:67
msgid ""
"To identify different variables, we use the variable description. There are "
"four types of description:\n"
"\n"
" - name_and_description: which contains the variable name followed by "
"its description\n"
" - path: the variable's path\n"
" - name: the variable name\n"
" - description: the variable's description"
msgstr ""
"Pour identifier les différentes variables, on utilise la description de la "
"variable. Il y a quatre type de descriptions:\n"
"\n"
" - name_and_description : qui contient le nom de la variable suivi de sa "
"description\n"
" - path : le chemin de la variable\n"
" - name : le nom de la variable\n"
" - description : la description de la variable"
#: src/rougail/cli/config.py:81
msgid "Modes that should not be accessible in read_write mode"
msgstr "Modes quoi doivent être inaccessible en mode lecture-écriture"
#: src/rougail/cli/config.py:88 src/rougail/cli/config.py:105
msgid "if any mode is set in \"modes_level\""
msgstr "si aucun mode n'est défini dans \"modes_level\""
#: src/rougail/cli/config.py:95 src/rougail/cli/config.py:112
msgid "mode must exists in \"modes_level\""
msgstr "un mode doit exister dans \"modes_level\""
#: src/rougail/cli/config.py:98
msgid "Modes that should not be accessible"
msgstr "Modes quoi doivent être inaccessible"
#~ msgid "do not display debug informations" #~ msgid "do not display debug informations"
#~ msgstr "ne pas afficher les informations de debug" #~ msgstr "ne pas afficher les informations de debug"

View file

@ -5,7 +5,7 @@
msgid "" msgid ""
msgstr "" msgstr ""
"Project-Id-Version: PACKAGE VERSION\n" "Project-Id-Version: PACKAGE VERSION\n"
"POT-Creation-Date: 2025-05-14 08:25+0200\n" "POT-Creation-Date: 2025-12-22 15:31+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
@ -15,15 +15,19 @@ msgstr ""
"Generated-By: pygettext.py 1.5\n" "Generated-By: pygettext.py 1.5\n"
#: src/rougail/cli/__main__.py:170 #: src/rougail/cli/__main__.py:237
msgid "cannot find \"user_data\" module \"{0}\"" msgid "cannot find \"user_data\" module \"{0}\""
msgstr "" msgstr ""
#: src/rougail/cli/__main__.py:214 #: src/rougail/cli/__main__.py:245
msgid "interactive user data \"{0}\" is loader before uninteractive user data \"{1}\""
msgstr ""
#: src/rougail/cli/__main__.py:281
msgid "cannot find cli file for \"output_name\" module \"{0}\"" msgid "cannot find cli file for \"output_name\" module \"{0}\""
msgstr "" msgstr ""
#: src/rougail/cli/__main__.py:240 #: src/rougail/cli/__main__.py:306
msgid "ERROR: {0}" msgid "ERROR: {0}"
msgstr "" msgstr ""
@ -39,11 +43,61 @@ msgstr ""
msgid "Displays debug informations" msgid "Displays debug informations"
msgstr "" msgstr ""
#: src/rougail/cli/config.py:43 #: src/rougail/cli/config.py:41
msgid "Displays command line option warnings informations" msgid "Displays command line option warnings informations"
msgstr "" msgstr ""
#: src/rougail/cli/config.py:47 #: src/rougail/cli/config.py:43
msgid "Displays Rougail version and all its components" msgid "Displays Rougail version and all its components"
msgstr "" msgstr ""
#: src/rougail/cli/config.py:45
msgid "Invalid value in user data is not allowed"
msgstr ""
#: src/rougail/cli/config.py:47
msgid "Unknown variable in user data is not allowed"
msgstr ""
#: src/rougail/cli/config.py:50
msgid "Open each user data in separate layers"
msgstr ""
#: src/rougail/cli/config.py:56
msgid "if only one user data is set in \"__.step.user_data\""
msgstr ""
#: src/rougail/cli/config.py:62
msgid "Configuration in output step is in read_write mode"
msgstr ""
#: src/rougail/cli/config.py:65
msgid "Type of variables description"
msgstr ""
#: src/rougail/cli/config.py:67
msgid ""
"To identify different variables, we use the variable description. There are four types of description:\n"
"\n"
" - name_and_description: which contains the variable name followed by its description\n"
" - path: the variable's path\n"
" - name: the variable name\n"
" - description: the variable's description"
msgstr ""
#: src/rougail/cli/config.py:81
msgid "Modes that should not be accessible in read_write mode"
msgstr ""
#: src/rougail/cli/config.py:88 src/rougail/cli/config.py:105
msgid "if any mode is set in \"modes_level\""
msgstr ""
#: src/rougail/cli/config.py:95 src/rougail/cli/config.py:112
msgid "mode must exists in \"modes_level\""
msgstr ""
#: src/rougail/cli/config.py:98
msgid "Modes that should not be accessible"
msgstr ""

View file

@ -242,7 +242,7 @@ def load_user_data(rougailconfig):
interactive_user_data.setdefault(layer_name, {})[user_data_name] = rougail_user_data interactive_user_data.setdefault(layer_name, {})[user_data_name] = rougail_user_data
continue continue
elif interactive_user_data: elif interactive_user_data:
raise Exception(_(f'interactive user datas "{0}" is loader before uninteractive user datas "{1}"').format(list(interactive_user_data), user_data_name)) raise Exception(_('interactive user data "{0}" is loader before uninteractive user data "{1}"').format(list(interactive_user_data), user_data_name))
for ud in rougail_user_data( for ud in rougail_user_data(
subconfig, subconfig,
rougailconfig=rougailconfig, rougailconfig=rougailconfig,

View file

@ -42,17 +42,18 @@ cli:
versions: false # {_('Displays Rougail version and all its components')} versions: false # {_('Displays Rougail version and all its components')}
invalid_user_data_error: false # {_("Invalid value in user datas is not allowed")} invalid_user_data_error: false # {_("Invalid value in user data is not allowed")}
unknown_user_data_error: false # {_("Unknown variable in user datas is not allowed")} unknown_user_data_error: false # {_("Unknown variable in user data is not allowed")}
layers: layers:
description: {_('Open each user datas in separate layers')} description: {_('Open each user data in separate layers')}
default: false default: false
hidden: hidden:
jinja: |- jinja: |-
{{{{ __.step.user_data is propertyerror or __.step.user_data | length < 2 }}}} {{{{ __.step.user_data is propertyerror or __.step.user_data | length < 2 }}}}
return_type: boolean return_type: boolean
description: {_('if only one user data is set in "__.step.user_data"')}
load_config: load_config:
default: true default: true
@ -82,15 +83,16 @@ cli:
mandatory: false mandatory: false
disabled: disabled:
jinja: | jinja: |
{{% if not modes_level %}} {{{{ not modes_level }}}}
No mode return_type: boolean
{{% endif %}} description: {_('if any mode is set in "modes_level"')}
validators: validators:
- type: jinja - type: jinja
jinja: | jinja: |
{{% if _.inaccessible_read_write_modes not in modes_level %}} {{% if _.inaccessible_read_write_modes not in modes_level %}}
not in modes_level ({{modes_level}}) not in modes_level ({{modes_level}})
{{% endif %}} {{% endif %}}
description: {_('mode must exists in "modes_level"')}
inaccessible_modes: inaccessible_modes:
description: {_('Modes that should not be accessible')} description: {_('Modes that should not be accessible')}
@ -98,15 +100,16 @@ cli:
mandatory: false mandatory: false
disabled: disabled:
jinja: | jinja: |
{{% if not modes_level %}} {{{{ not modes_level }}}}
No mode return_type: boolean
{{% endif %}} description: {_('if any mode is set in "modes_level"')}
validators: validators:
- type: jinja - type: jinja
jinja: | jinja: |
{{% if _.inaccessible_modes not in modes_level %}} {{% if _.inaccessible_modes not in modes_level %}}
not in modes_level ({{modes_level}}) not in modes_level ({{modes_level}})
{{% endif %}} {{% endif %}}
description: {_('mode must exists in "modes_level"')}
""" """
return { return {
"options": options, "options": options,