WIP: Expand the developer documentation #27

Draft
gremond wants to merge 204 commits from develop into developer_docs
13 changed files with 1544 additions and 463 deletions
Showing only changes of commit c39e232fa9 - Show all commits

210
README.fr.md Normal file
View file

@ -0,0 +1,210 @@
---
gitea: none
include_toc: true
---
[🇬🇧 (EN)](README.md) - [🇫🇷 (FR)](README.fr.md)
| Variable | Description | Valeur par défaut | Type | Contrôle des accès | Validateur |
|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------|----------------------|----------------------------------------------------------------------------------------------------------------------------------------------------|
| **<a id="default_structural_format_version" name="default_structural_format_version">default_structural_format_version</a>**<br/>**Ligne de commande** : -v, --default_structural_format_version<br/>**Variable d'environnement** : DEFAULT_STRUCTURAL_FORMAT_VERSION | Version par défaut du format des fichiers de structure.<br/>Cette valeur n&#x27;est utilisée que si la version n&#x27;est pas définie dans le fichier de structure. | | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choix** : <br/>&nbsp;1.0<br/>&nbsp;1.1<br/>&nbsp;null |
| **<a id="functions_files" name="functions_files">functions_files</a>**<br/>**Ligne de commande** : -c, --functions_files<br/>**Variable d'environnement** : FUNCTIONS_FILES | Fichier avec les fonctions.<br/>Ce fichier contient des filtres et des fonctions Jinja2 supplémentaires utilisables dans les fichiers de structure. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique`<br/>&nbsp;le nom de fichier peut être une chemin relatif<br/>&nbsp;le fichier doit exister<br/>&nbsp;type de fichier autorisé: "file". |
| **<a id="modes_level" name="modes_level">modes_level</a>**<br/>**Ligne de commande** : --modes_level<br/>**Variable d'environnement** : MODES_LEVEL | Tous les niveaux de modes valides. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique` |
| **<a id="default_family_mode" name="default_family_mode">default_family_mode</a>**<br/>**Variable d'environnement** : DEFAULT_FAMILY_MODE | Mode par défaut pour une famille. | le premier défini dans "[Tous les niveaux de modes valides](#modes_level)" | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | Ce mode doit être disponible dans "[Tous les niveaux de modes valides](#modes_level)". |
| **<a id="default_variable_mode" name="default_variable_mode">default_variable_mode</a>**<br/>**Variable d'environnement** : DEFAULT_VARIABLE_MODE | Mode par défaut pour une variable. | si la variable "[Tous les niveaux de modes valides](#modes_level)" est définit, la valeur par défaut est le second élément disponible, sinon, le premier | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | Ce mode doit être disponible dans "[Tous les niveaux de modes valides](#modes_level)". |
| **<a id="base_option_name" name="base_option_name">base_option_name</a>**<br/>**Variable d'environnement** : BASE_OPTION_NAME | Nom de l&#x27;option pour l&#x27;option de base. | baseoption | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="export_with_import" name="export_with_import">export_with_import</a>**<br/>**Variable d'environnement** : EXPORT_WITH_IMPORT | Dans le fichier de cache, ne pas importer Tiramisu et autres dépendances. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="tiramisu_cache" name="tiramisu_cache">tiramisu_cache</a>**<br/>**Ligne de commande** : -t, --tiramisu_cache<br/>**Variable d'environnement** : TIRAMISU_CACHE | Store Tiramisu cache filename.<br/>Ce fichier contient les instructions Tiramisu utilisé en interne pour charger les variables.<br/>Ce fichier peut être utilisé pour le débogage. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | •&nbsp;le nom de fichier peut être une chemin relatif<br/>&nbsp;type de fichier autorisé: "file". |
| **<a id="internal_functions" name="internal_functions">internal_functions</a>**<br/>**Variable d'environnement** : INTERNAL_FUNCTIONS | Nom des fonctions internes qu&#x27;il est possible d&#x27;utiliser comme fonction. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | |
| **<a id="extra_annotators" name="extra_annotators">extra_annotators</a>**<br/>**Variable d'environnement** : EXTRA_ANNOTATORS | Nom des annotators supplémentaires. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | |
| **<a id="suffix" name="suffix">suffix</a>**<br/>**Variable d'environnement** : SUFFIX | Suffix ajouté pour généré le nom des options. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="force_optional" name="force_optional">force_optional</a>**<br/>**Ligne de commande** : <br/>&nbsp;--force_optional<br/>&nbsp;--no-force_optional<br/>**Variable d'environnement** : FORCE_OPTIONAL | Toutes les variables dans un calcul sont optionnelles. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | `standard` | |
| **<a id="load_unexist_redefine" name="load_unexist_redefine">load_unexist_redefine</a>**<br/>**Variable d'environnement** : LOAD_UNEXIST_REDEFINE | Charger les variables redéfinis même si elles n&#x27;existe pas. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
## Le gestionnaire de secret
> [!NOTE]
>
> **Chemin** : secret_manager\
> `standard`
| Variable | Description | Valeur par défaut | Type | Contrôle des accès |
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------|--------------------------------------------------------------------------------------------------|----------------------|
| **<a id="secret_manager.pattern" name="secret_manager.pattern">secret_manager.pattern</a>**<br/>**Ligne de commande** : --secret_manager.pattern<br/>**Variable d'environnement** : SECRET_MANAGER.PATTERN | Le modèle de secret permettant de construire le nom de l&#x27;élément recherché dans le gestionnaire de secrets.<br/>Le modèle est au format Jinja2. | {{ project }} - {{ environment }} - {{ service }} - {{ user }} | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | `standard` |
## Load and exporter steps
> [!NOTE]
>
> **Chemin** : step\
> `standard`
| Variable | Description | Valeur par défaut | Type | Contrôle des accès | Validateur |
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------|---------------------|--------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| **<a id="step.structural" name="step.structural">step.structural</a>**<br/>**Variable d'environnement** : STEP.STRUCTURAL | Sélection pour structure. | •&nbsp;directory | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | **Choix** : <br/>&nbsp;directory<br/>&nbsp;string<br/>&nbsp;commandline<br/>&nbsp;risotto<br/>&nbsp;bitwarden |
| **<a id="step.user_data" name="step.user_data">step.user_data</a>**<br/>**Ligne de commande** : -u, --step.user_data<br/>**Variable d'environnement** : STEP.USER_DATA | Sélection pour données utilisateur. | | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` *`désactivé`*<br/>**Désactivé** : _('cannot load user data for doc output') | `unique`<br/>**Choix** : <br/>&nbsp;yaml<br/>&nbsp;environment<br/>&nbsp;commandline<br/>&nbsp;ansible<br/>&nbsp;questionary<br/>&nbsp;risotto<br/>&nbsp;bitwarden |
| **<a id="step.output" name="step.output">step.output</a>**<br/>**Ligne de commande** : -o, --step.output<br/>**Variable d'environnement** : STEP.OUTPUT | Sélection pour sortie. | display | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | `standard` | **Choix** : <br/>&nbsp;display<br/>&nbsp;json<br/>&nbsp;doc<br/>&nbsp;table<br/>&nbsp;ansible |
| Variable | Description | Valeur par défaut | Type | Contrôle des accès |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------|---------------------|---------------------------------------------------------------------------------------------------|----------------------|
| **<a id="define_default_params" name="define_default_params">define_default_params</a>**<br/>**Ligne de commande** : <br/>&nbsp;--define_default_params<br/>&nbsp;--no-define_default_params<br/>**Variable d'environnement** : DEFINE_DEFAULT_PARAMS | Sur charger les paramètre par défaut pour le type d&#x27;option. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | `standard` |
## Paramètre par défaut pour le type d&#x27;option
> [!NOTE]
>
> **Chemin** : default_params\
> `standard` *`désactivé`*\
> **Désactivé** : lorsque la variable "[Sur charger les paramètre par défaut pour le type d&#x27;option](#define_default_params)" a la valeur "false"
### UNIX filename
> [!NOTE]
>
> **Chemin** : default_params.unix_filename\
> `standard`
| Variable | Description | Valeur par défaut | Type | Contrôle des accès | Validateur |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------|----------------------------------|-----------------------------------------------------------------------------------------------|----------------------|----------------------------------------------------------------|
| **<a id="default_params.unix_filename.allow_relative" name="default_params.unix_filename.allow_relative">default_params.unix_filename.allow_relative</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.unix_filename.allow_relative<br/>&nbsp;--default_params.unix_filename.no-allow_relative<br/>**Variable d'environnement** : DEFAULT_PARAMS.UNIX_FILENAME.ALLOW_RELATIVE | Le nom de fichier peut être une chemin relatif. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.unix_filename.test_existence" name="default_params.unix_filename.test_existence">default_params.unix_filename.test_existence</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.unix_filename.test_existence<br/>&nbsp;--default_params.unix_filename.no-test_existence<br/>**Variable d'environnement** : DEFAULT_PARAMS.UNIX_FILENAME.TEST_EXISTENCE | Le fichier doit exister. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.unix_filename.types" name="default_params.unix_filename.types">default_params.unix_filename.types</a>**<br/>**Ligne de commande** : --default_params.unix_filename.types<br/>**Variable d'environnement** : DEFAULT_PARAMS.UNIX_FILENAME.TYPES | Type de fichier autorisé. | •&nbsp;file<br/>&nbsp;directory | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique`<br/>**Choix** : <br/>&nbsp;file<br/>&nbsp;directory |
### IP
> [!NOTE]
>
> **Chemin** : default_params.ip\
> `standard`
| Variable | Description | Valeur par défaut | Type | Contrôle des accès |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------|---------------------|-------------------------------------------------------------------------------------|----------------------|
| **<a id="default_params.ip.private_only" name="default_params.ip.private_only">default_params.ip.private_only</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.ip.private_only<br/>&nbsp;--default_params.ip.no-private_only<br/>**Variable d'environnement** : DEFAULT_PARAMS.IP.PRIVATE_ONLY | Les IP privées sont autorisées. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.ip.allow_reserved" name="default_params.ip.allow_reserved">default_params.ip.allow_reserved</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.ip.allow_reserved<br/>&nbsp;--default_params.ip.no-allow_reserved<br/>**Variable d'environnement** : DEFAULT_PARAMS.IP.ALLOW_RESERVED | Les IP réservées sont autorisés. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.ip.cidr" name="default_params.ip.cidr">default_params.ip.cidr</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.ip.cidr<br/>&nbsp;--default_params.ip.no-cidr<br/>**Variable d'environnement** : DEFAULT_PARAMS.IP.CIDR | L&#x27;IP doit être au format CIDR. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
### CIDR
> [!NOTE]
>
> **Chemin** : default_params.cidr\
> `standard`
| Variable | Description | Valeur par défaut | Type | Contrôle des accès |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------|---------------------|-------------------------------------------------------------------------------------|----------------------|
| **<a id="default_params.cidr.private_only" name="default_params.cidr.private_only">default_params.cidr.private_only</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.cidr.private_only<br/>&nbsp;--default_params.cidr.no-private_only<br/>**Variable d'environnement** : DEFAULT_PARAMS.CIDR.PRIVATE_ONLY | Les IP privées sont autorisées. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.cidr.allow_reserved" name="default_params.cidr.allow_reserved">default_params.cidr.allow_reserved</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.cidr.allow_reserved<br/>&nbsp;--default_params.cidr.no-allow_reserved<br/>**Variable d'environnement** : DEFAULT_PARAMS.CIDR.ALLOW_RESERVED | Les IP réservées sont autorisés. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.cidr.cidr" name="default_params.cidr.cidr">default_params.cidr.cidr</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.cidr.cidr<br/>&nbsp;--default_params.cidr.no-cidr<br/>**Variable d'environnement** : DEFAULT_PARAMS.CIDR.CIDR | L&#x27;IP doit être au format CIDR. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
### Network
> [!NOTE]
>
> **Chemin** : default_params.network\
> `standard`
| Variable | Description | Valeur par défaut | Type | Contrôle des accès |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------|---------------------|-------------------------------------------------------------------------------------|----------------------|
| **<a id="default_params.network.private_only" name="default_params.network.private_only">default_params.network.private_only</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.network.private_only<br/>&nbsp;--default_params.network.no-private_only<br/>**Variable d'environnement** : DEFAULT_PARAMS.NETWORK.PRIVATE_ONLY | Les réseaux privés sont autorisés. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.network.allow_reserved" name="default_params.network.allow_reserved">default_params.network.allow_reserved</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.network.allow_reserved<br/>&nbsp;--default_params.network.no-allow_reserved<br/>**Variable d'environnement** : DEFAULT_PARAMS.NETWORK.ALLOW_RESERVED | Les réseaux réservés sont autorisés. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.network.cidr" name="default_params.network.cidr">default_params.network.cidr</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.network.cidr<br/>&nbsp;--default_params.network.no-cidr<br/>**Variable d'environnement** : DEFAULT_PARAMS.NETWORK.CIDR | Le réseau doit être au format CIDR. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
### Network CIDR
> [!NOTE]
>
> **Chemin** : default_params.network_cidr\
> `standard`
| Variable | Description | Valeur par défaut | Type | Contrôle des accès |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------|---------------------|-------------------------------------------------------------------------------------|----------------------|
| **<a id="default_params.network_cidr.private_only" name="default_params.network_cidr.private_only">default_params.network_cidr.private_only</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.network_cidr.private_only<br/>&nbsp;--default_params.network_cidr.no-private_only<br/>**Variable d'environnement** : DEFAULT_PARAMS.NETWORK_CIDR.PRIVATE_ONLY | Les réseaux privés sont autorisés. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.network_cidr.allow_reserved" name="default_params.network_cidr.allow_reserved">default_params.network_cidr.allow_reserved</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.network_cidr.allow_reserved<br/>&nbsp;--default_params.network_cidr.no-allow_reserved<br/>**Variable d'environnement** : DEFAULT_PARAMS.NETWORK_CIDR.ALLOW_RESERVED | Les réseaux réservés sont autorisés. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.network_cidr.cidr" name="default_params.network_cidr.cidr">default_params.network_cidr.cidr</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.network_cidr.cidr<br/>&nbsp;--default_params.network_cidr.no-cidr<br/>**Variable d'environnement** : DEFAULT_PARAMS.NETWORK_CIDR.CIDR | Le réseau doit être au format CIDR. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
### Netbios
> [!NOTE]
>
> **Chemin** : default_params.netbios\
> `standard`
| Variable | Description | Valeur par défaut | Type | Contrôle des accès | Validateur |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------|---------------------|-------------------------------------------------------------------------------------|----------------------|-------------------------------------------------------------------------------------------|
| **<a id="default_params.netbios.type" name="default_params.netbios.type">default_params.netbios.type</a>**<br/>**Ligne de commande** : --default_params.netbios.type<br/>**Variable d'environnement** : DEFAULT_PARAMS.NETBIOS.TYPE | Type de nom de domaine. | netbios | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choix** : <br/>&nbsp;domainname<br/>&nbsp;netbios<br/>&nbsp;hostname<br/>&nbsp;null |
| **<a id="default_params.netbios.allow_without_dot" name="default_params.netbios.allow_without_dot">default_params.netbios.allow_without_dot</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.netbios.allow_without_dot<br/>&nbsp;--default_params.netbios.no-allow_without_dot<br/>**Variable d'environnement** : DEFAULT_PARAMS.NETBIOS.ALLOW_WITHOUT_DOT | Le nom de domaine peut être un nom d&#x27;hôte. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.netbios.test_existence" name="default_params.netbios.test_existence">default_params.netbios.test_existence</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.netbios.test_existence<br/>&nbsp;--default_params.netbios.no-test_existence<br/>**Variable d'environnement** : DEFAULT_PARAMS.NETBIOS.TEST_EXISTENCE | Le nom de domaine doit exister. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.netbios.allow_ip" name="default_params.netbios.allow_ip">default_params.netbios.allow_ip</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.netbios.allow_ip<br/>&nbsp;--default_params.netbios.no-allow_ip<br/>**Variable d'environnement** : DEFAULT_PARAMS.NETBIOS.ALLOW_IP | Le nom de domaine peut être une IP. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.netbios.allow_cidr_network" name="default_params.netbios.allow_cidr_network">default_params.netbios.allow_cidr_network</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.netbios.allow_cidr_network<br/>&nbsp;--default_params.netbios.no-allow_cidr_network<br/>**Variable d'environnement** : DEFAULT_PARAMS.NETBIOS.ALLOW_CIDR_NETWORK | Le nom de domaine peut être un réseau au format CIDR. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.netbios.allow_startswith_dot" name="default_params.netbios.allow_startswith_dot">default_params.netbios.allow_startswith_dot</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.netbios.allow_startswith_dot<br/>&nbsp;--default_params.netbios.no-allow_startswith_dot<br/>**Variable d'environnement** : DEFAULT_PARAMS.NETBIOS.ALLOW_STARTSWITH_DOT | Le nom de domaine peut démarré par un point. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
### Domainname
> [!NOTE]
>
> **Chemin** : default_params.domainname\
> `standard`
| Variable | Description | Valeur par défaut | Type | Contrôle des accès | Validateur |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------|---------------------|-------------------------------------------------------------------------------------|----------------------|-------------------------------------------------------------------------------------------|
| **<a id="default_params.domainname.type" name="default_params.domainname.type">default_params.domainname.type</a>**<br/>**Ligne de commande** : --default_params.domainname.type<br/>**Variable d'environnement** : DEFAULT_PARAMS.DOMAINNAME.TYPE | Type de nom de domaine. | domainname | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choix** : <br/>&nbsp;domainname<br/>&nbsp;netbios<br/>&nbsp;hostname<br/>&nbsp;null |
| **<a id="default_params.domainname.allow_without_dot" name="default_params.domainname.allow_without_dot">default_params.domainname.allow_without_dot</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.domainname.allow_without_dot<br/>&nbsp;--default_params.domainname.no-allow_without_dot<br/>**Variable d'environnement** : DEFAULT_PARAMS.DOMAINNAME.ALLOW_WITHOUT_DOT | Le nom de domaine peut être un nom d&#x27;hôte. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.domainname.test_existence" name="default_params.domainname.test_existence">default_params.domainname.test_existence</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.domainname.test_existence<br/>&nbsp;--default_params.domainname.no-test_existence<br/>**Variable d'environnement** : DEFAULT_PARAMS.DOMAINNAME.TEST_EXISTENCE | Le nom de domaine doit exister. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.domainname.allow_ip" name="default_params.domainname.allow_ip">default_params.domainname.allow_ip</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.domainname.allow_ip<br/>&nbsp;--default_params.domainname.no-allow_ip<br/>**Variable d'environnement** : DEFAULT_PARAMS.DOMAINNAME.ALLOW_IP | Le nom de domaine peut être une IP. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.domainname.allow_cidr_network" name="default_params.domainname.allow_cidr_network">default_params.domainname.allow_cidr_network</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.domainname.allow_cidr_network<br/>&nbsp;--default_params.domainname.no-allow_cidr_network<br/>**Variable d'environnement** : DEFAULT_PARAMS.DOMAINNAME.ALLOW_CIDR_NETWORK | Le nom de domaine peut être un réseau au format CIDR. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.domainname.allow_startswith_dot" name="default_params.domainname.allow_startswith_dot">default_params.domainname.allow_startswith_dot</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.domainname.allow_startswith_dot<br/>&nbsp;--default_params.domainname.no-allow_startswith_dot<br/>**Variable d'environnement** : DEFAULT_PARAMS.DOMAINNAME.ALLOW_STARTSWITH_DOT | Le nom de domaine peut démarré par un point. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
### Hostname
> [!NOTE]
>
> **Chemin** : default_params.hostname\
> `standard`
| Variable | Description | Valeur par défaut | Type | Contrôle des accès | Validateur |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------|---------------------|-------------------------------------------------------------------------------------|----------------------|-------------------------------------------------------------------------------------------|
| **<a id="default_params.hostname.type" name="default_params.hostname.type">default_params.hostname.type</a>**<br/>**Ligne de commande** : --default_params.hostname.type<br/>**Variable d'environnement** : DEFAULT_PARAMS.HOSTNAME.TYPE | Type de nom de domaine. | hostname | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choix** : <br/>&nbsp;domainname<br/>&nbsp;netbios<br/>&nbsp;hostname<br/>&nbsp;null |
| **<a id="default_params.hostname.allow_without_dot" name="default_params.hostname.allow_without_dot">default_params.hostname.allow_without_dot</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.hostname.allow_without_dot<br/>&nbsp;--default_params.hostname.no-allow_without_dot<br/>**Variable d'environnement** : DEFAULT_PARAMS.HOSTNAME.ALLOW_WITHOUT_DOT | Le nom de domaine peut être un nom d&#x27;hôte. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.hostname.test_existence" name="default_params.hostname.test_existence">default_params.hostname.test_existence</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.hostname.test_existence<br/>&nbsp;--default_params.hostname.no-test_existence<br/>**Variable d'environnement** : DEFAULT_PARAMS.HOSTNAME.TEST_EXISTENCE | Le nom de domaine doit exister. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.hostname.allow_ip" name="default_params.hostname.allow_ip">default_params.hostname.allow_ip</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.hostname.allow_ip<br/>&nbsp;--default_params.hostname.no-allow_ip<br/>**Variable d'environnement** : DEFAULT_PARAMS.HOSTNAME.ALLOW_IP | Le nom de domaine peut être une IP. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.hostname.allow_cidr_network" name="default_params.hostname.allow_cidr_network">default_params.hostname.allow_cidr_network</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.hostname.allow_cidr_network<br/>&nbsp;--default_params.hostname.no-allow_cidr_network<br/>**Variable d'environnement** : DEFAULT_PARAMS.HOSTNAME.ALLOW_CIDR_NETWORK | Le nom de domaine peut être un réseau au format CIDR. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.hostname.allow_startswith_dot" name="default_params.hostname.allow_startswith_dot">default_params.hostname.allow_startswith_dot</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.hostname.allow_startswith_dot<br/>&nbsp;--default_params.hostname.no-allow_startswith_dot<br/>**Variable d'environnement** : DEFAULT_PARAMS.HOSTNAME.ALLOW_STARTSWITH_DOT | Le nom de domaine peut démarré par un point. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
### Web address
> [!NOTE]
>
> **Chemin** : default_params.web_address\
> `standard`
| Variable | Description | Valeur par défaut | Type | Contrôle des accès | Validateur |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------|---------------------|-------------------------------------------------------------------------------------|----------------------|-------------------------------------------------------------------------------------------|
| **<a id="default_params.web_address.type" name="default_params.web_address.type">default_params.web_address.type</a>**<br/>**Ligne de commande** : --default_params.web_address.type<br/>**Variable d'environnement** : DEFAULT_PARAMS.WEB_ADDRESS.TYPE | Type de nom de domaine. | domainname | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choix** : <br/>&nbsp;domainname<br/>&nbsp;netbios<br/>&nbsp;hostname<br/>&nbsp;null |
| **<a id="default_params.web_address.allow_without_dot" name="default_params.web_address.allow_without_dot">default_params.web_address.allow_without_dot</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.web_address.allow_without_dot<br/>&nbsp;--default_params.web_address.no-allow_without_dot<br/>**Variable d'environnement** : DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_WITHOUT_DOT | Le nom de domaine peut être un nom d&#x27;hôte. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.test_existence" name="default_params.web_address.test_existence">default_params.web_address.test_existence</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.web_address.test_existence<br/>&nbsp;--default_params.web_address.no-test_existence<br/>**Variable d'environnement** : DEFAULT_PARAMS.WEB_ADDRESS.TEST_EXISTENCE | Le nom de domaine doit exister. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_ip" name="default_params.web_address.allow_ip">default_params.web_address.allow_ip</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.web_address.allow_ip<br/>&nbsp;--default_params.web_address.no-allow_ip<br/>**Variable d'environnement** : DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_IP | Le nom de domaine peut être une IP. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_cidr_network" name="default_params.web_address.allow_cidr_network">default_params.web_address.allow_cidr_network</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.web_address.allow_cidr_network<br/>&nbsp;--default_params.web_address.no-allow_cidr_network<br/>**Variable d'environnement** : DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_CIDR_NETWORK | Le nom de domaine peut être un réseau au format CIDR. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_startswith_dot" name="default_params.web_address.allow_startswith_dot">default_params.web_address.allow_startswith_dot</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.web_address.allow_startswith_dot<br/>&nbsp;--default_params.web_address.no-allow_startswith_dot<br/>**Variable d'environnement** : DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_STARTSWITH_DOT | Le nom de domaine peut démarré par un point. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_range" name="default_params.web_address.allow_range">default_params.web_address.allow_range</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.web_address.allow_range<br/>&nbsp;--default_params.web_address.no-allow_range<br/>**Variable d'environnement** : DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_RANGE | Peut être une plage de port. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_protocol" name="default_params.web_address.allow_protocol">default_params.web_address.allow_protocol</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.web_address.allow_protocol<br/>&nbsp;--default_params.web_address.no-allow_protocol<br/>**Variable d'environnement** : DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_PROTOCOL | Peut avoir le protocole. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_zero" name="default_params.web_address.allow_zero">default_params.web_address.allow_zero</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.web_address.allow_zero<br/>&nbsp;--default_params.web_address.no-allow_zero<br/>**Variable d'environnement** : DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_ZERO | Port 0 est autorisé. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_wellknown" name="default_params.web_address.allow_wellknown">default_params.web_address.allow_wellknown</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.web_address.allow_wellknown<br/>&nbsp;--default_params.web_address.no-allow_wellknown<br/>**Variable d'environnement** : DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_WELLKNOWN | Les ports connus (1 à 1023) sont autorisés. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_registred" name="default_params.web_address.allow_registred">default_params.web_address.allow_registred</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.web_address.allow_registred<br/>&nbsp;--default_params.web_address.no-allow_registred<br/>**Variable d'environnement** : DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_REGISTRED | Les ports enregistrés (1024 à 49151) sont autorisés. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_private" name="default_params.web_address.allow_private">default_params.web_address.allow_private</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.web_address.allow_private<br/>&nbsp;--default_params.web_address.no-allow_private<br/>**Variable d'environnement** : DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_PRIVATE | Les ports privés (supérieur à 49152) sont autorisés. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
### Port
> [!NOTE]
>
> **Chemin** : default_params.port\
> `standard`
| Variable | Description | Valeur par défaut | Type | Contrôle des accès |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------|---------------------|-------------------------------------------------------------------------------------|----------------------|
| **<a id="default_params.port.allow_range" name="default_params.port.allow_range">default_params.port.allow_range</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.port.allow_range<br/>&nbsp;--default_params.port.no-allow_range<br/>**Variable d'environnement** : DEFAULT_PARAMS.PORT.ALLOW_RANGE | Peut être une plage de port. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.port.allow_protocol" name="default_params.port.allow_protocol">default_params.port.allow_protocol</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.port.allow_protocol<br/>&nbsp;--default_params.port.no-allow_protocol<br/>**Variable d'environnement** : DEFAULT_PARAMS.PORT.ALLOW_PROTOCOL | Peut avoir le protocole. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.port.allow_zero" name="default_params.port.allow_zero">default_params.port.allow_zero</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.port.allow_zero<br/>&nbsp;--default_params.port.no-allow_zero<br/>**Variable d'environnement** : DEFAULT_PARAMS.PORT.ALLOW_ZERO | Port 0 est autorisé. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.port.allow_wellknown" name="default_params.port.allow_wellknown">default_params.port.allow_wellknown</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.port.allow_wellknown<br/>&nbsp;--default_params.port.no-allow_wellknown<br/>**Variable d'environnement** : DEFAULT_PARAMS.PORT.ALLOW_WELLKNOWN | Les ports connus (1 à 1023) sont autorisés. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.port.allow_registred" name="default_params.port.allow_registred">default_params.port.allow_registred</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.port.allow_registred<br/>&nbsp;--default_params.port.no-allow_registred<br/>**Variable d'environnement** : DEFAULT_PARAMS.PORT.ALLOW_REGISTRED | Les ports enregistrés (1024 à 49151) sont autorisés. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.port.allow_private" name="default_params.port.allow_private">default_params.port.allow_private</a>**<br/>**Ligne de commande** : <br/>&nbsp;--default_params.port.allow_private<br/>&nbsp;--default_params.port.no-allow_private<br/>**Variable d'environnement** : DEFAULT_PARAMS.PORT.ALLOW_PRIVATE | Les ports privés (supérieur à 49152) sont autorisés. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |

287
README.md
View file

@ -1,105 +1,210 @@
![Logo Rougail](logo.png "logo rougail")
# Rougail
## Description
Rougail is a free full-featured configuration manager library written in python3.
The configuration is describe in YAML dictionary files.
Those dictionaries are converted into [Tiramisu](https://framagit.org/tiramisu/tiramisu) objects.
Rougail can be incorporated with other technologies and stacks regardless of whether theyre written in Python or not.
## Simple example
Create a directory:
```bash
# mkdir dict
```
## Dictionary
A dictionary is a variables description file.
Create the file `dict/dictionary.yml`:
```yml
--- ---
version: 1.1 gitea: none
# describe a variable my_first_variable include_toc: true
# and a family with a variable my_second_variable ---
my_first_variable: my_value [🇬🇧 (EN)](README.md) - [🇫🇷 (FR)](README.fr.md)
my_family:
my_second_variable: 1
```
## Generate variable | Variable | Description | Default value | Type | Access control | Validator |
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------|------------------|----------------------------------------------------------------------------------------------------------------------------------|
| **<a id="default_structural_format_version" name="default_structural_format_version">default_structural_format_version</a>**<br/>**Command line**: -v, --default_structural_format_version<br/>**Environment variable**: DEFAULT_STRUCTURAL_FORMAT_VERSION | Default version of the structural file format.<br/>This value is only used if the version is not set in the structural file. | | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choices**: <br/>&nbsp;1.0<br/>&nbsp;1.1<br/>&nbsp;null |
| **<a id="functions_files" name="functions_files">functions_files</a>**<br/>**Command line**: -c, --functions_files<br/>**Environment variable**: FUNCTIONS_FILES | File with functions.<br/>This file contains filters and additional Jinja2 functions usable in structure files. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique`<br/>&nbsp;this filename could be a relative path<br/>&nbsp;this file must exist<br/>&nbsp;file type allowed: "file". |
| **<a id="modes_level" name="modes_level">modes_level</a>**<br/>**Command line**: --modes_level<br/>**Environment variable**: MODES_LEVEL | All modes level available. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique` |
| **<a id="default_family_mode" name="default_family_mode">default_family_mode</a>**<br/>**Environment variable**: DEFAULT_FAMILY_MODE | Default mode for a family. | the first one defined in "[All modes level available](#modes_level)" | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | This mode must be available in "[All modes level available](#modes_level)". |
| **<a id="default_variable_mode" name="default_variable_mode">default_variable_mode</a>**<br/>**Environment variable**: DEFAULT_VARIABLE_MODE | Default mode for a variable. | if the variable "[All modes level available](#modes_level)" is defined, the default value is the second available element, otherwise, the first | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | This mode must be available in "[All modes level available](#modes_level)". |
| **<a id="base_option_name" name="base_option_name">base_option_name</a>**<br/>**Environment variable**: BASE_OPTION_NAME | Option name for the base option. | baseoption | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="export_with_import" name="export_with_import">export_with_import</a>**<br/>**Environment variable**: EXPORT_WITH_IMPORT | In cache file, do not importation of Tiramisu and other dependencies. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="tiramisu_cache" name="tiramisu_cache">tiramisu_cache</a>**<br/>**Command line**: -t, --tiramisu_cache<br/>**Environment variable**: TIRAMISU_CACHE | Store Tiramisu cache filename.<br/>This file contains the Tiramisu instructions used internally to load the variables.<br/>This file can be used for debugging. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | •&nbsp;this filename could be a relative path<br/>&nbsp;file type allowed: "file". |
| **<a id="internal_functions" name="internal_functions">internal_functions</a>**<br/>**Environment variable**: INTERNAL_FUNCTIONS | Name of internal functions that we can use as a function. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | |
| **<a id="extra_annotators" name="extra_annotators">extra_annotators</a>**<br/>**Environment variable**: EXTRA_ANNOTATORS | Name of extra annotators. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | |
| **<a id="suffix" name="suffix">suffix</a>**<br/>**Environment variable**: SUFFIX | Suffix add to generated options name. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="force_optional" name="force_optional">force_optional</a>**<br/>**Command line**: <br/>&nbsp;--force_optional<br/>&nbsp;--no-force_optional<br/>**Environment variable**: FORCE_OPTIONAL | Every variables in calculation are optionals. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | `standard` | |
| **<a id="load_unexist_redefine" name="load_unexist_redefine">load_unexist_redefine</a>**<br/>**Environment variable**: LOAD_UNEXIST_REDEFINE | Loads redefine variables even if there don&#x27;t already exists. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
### With commandline: ## The secret manager
```bash > [!NOTE]
# rougail -m dict >
Variables: > **Path**: secret_manager\
┣━━ 📓 my_first_variable: my_value > `standard`
┗━━ 📂 my_family
┗━━ 📓 my_second_variable: 1
``` | Variable | Description | Default value | Type | Access control |
|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------|------------------------------------------------------------------------------------------------|------------------|
| **<a id="secret_manager.pattern" name="secret_manager.pattern">secret_manager.pattern</a>**<br/>**Command line**: --secret_manager.pattern<br/>**Environment variable**: SECRET_MANAGER.PATTERN | The secret pattern to constructing the name of the item searched for in the secret manager.<br/>The pattern is in Jinja2 format. | {{ project }} - {{ environment }} - {{ service }} - {{ user }} | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | `standard` |
### With default value: ## Load and exporter steps
Here is a python3 example file: > [!NOTE]
>
> **Path**: step\
> `standard`
```python | Variable | Description | Default value | Type | Access control | Validator |
from rougail import Rougail, RougailConfig |-------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------|------------------|------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
from pprint import pprint | **<a id="step.structural" name="step.structural">step.structural</a>**<br/>**Environment variable**: STEP.STRUCTURAL | Select for structural. | •&nbsp;directory | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | **Choices**: <br/>&nbsp;directory<br/>&nbsp;string<br/>&nbsp;commandline<br/>&nbsp;risotto<br/>&nbsp;bitwarden |
| **<a id="step.user_data" name="step.user_data">step.user_data</a>**<br/>**Command line**: -u, --step.user_data<br/>**Environment variable**: STEP.USER_DATA | Select for user datas. | | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` *`disabled`*<br/>**Disabled**: _('cannot load user data for doc output') | `unique`<br/>**Choices**: <br/>&nbsp;yaml<br/>&nbsp;environment<br/>&nbsp;commandline<br/>&nbsp;ansible<br/>&nbsp;questionary<br/>&nbsp;risotto<br/>&nbsp;bitwarden |
| **<a id="step.output" name="step.output">step.output</a>**<br/>**Command line**: -o, --step.output<br/>**Environment variable**: STEP.OUTPUT | Select for output. | display | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | `standard` | **Choices**: <br/>&nbsp;display<br/>&nbsp;json<br/>&nbsp;doc<br/>&nbsp;table<br/>&nbsp;ansible |
RougailConfig['dictionaries_dir'] = ['dict'] | Variable | Description | Default value | Type | Access control |
rougail = Rougail() |----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------|-----------------|-------------------------------------------------------------------------------------------------|------------------|
config = rougail.run() | **<a id="define_default_params" name="define_default_params">define_default_params</a>**<br/>**Command line**: <br/>&nbsp;--define_default_params<br/>&nbsp;--no-define_default_params<br/>**Environment variable**: DEFINE_DEFAULT_PARAMS | Override default parameters for option type. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | `standard` |
pprint(config.value.get(), sort_dicts=False)
```
The result is: ## Default parameters for option type
```json > [!NOTE]
{<TiramisuOption path="rougail">: {<TiramisuOption path="rougail.my_first_variable">: 'my_value', >
<TiramisuOption path="rougail.my_family">: {<TiramisuOption path="rougail.my_family.my_second_variable">: 1}}} > **Path**: default_params\
``` > `standard` *`disabled`*\
> **Disabled**: when the variable "[Override default parameters for option type](#define_default_params)" has the value "false"
### With modified value ### UNIX filename
> [!NOTE]
>
> **Path**: default_params.unix_filename\
> `standard`
| Variable | Description | Default value | Type | Access control | Validator |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------|----------------------------------|-----------------------------------------------------------------------------------------------|------------------|-----------------------------------------------------------------|
| **<a id="default_params.unix_filename.allow_relative" name="default_params.unix_filename.allow_relative">default_params.unix_filename.allow_relative</a>**<br/>**Command line**: <br/>&nbsp;--default_params.unix_filename.allow_relative<br/>&nbsp;--default_params.unix_filename.no-allow_relative<br/>**Environment variable**: DEFAULT_PARAMS.UNIX_FILENAME.ALLOW_RELATIVE | This filename could be a relative path. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.unix_filename.test_existence" name="default_params.unix_filename.test_existence">default_params.unix_filename.test_existence</a>**<br/>**Command line**: <br/>&nbsp;--default_params.unix_filename.test_existence<br/>&nbsp;--default_params.unix_filename.no-test_existence<br/>**Environment variable**: DEFAULT_PARAMS.UNIX_FILENAME.TEST_EXISTENCE | This file must exist. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.unix_filename.types" name="default_params.unix_filename.types">default_params.unix_filename.types</a>**<br/>**Command line**: --default_params.unix_filename.types<br/>**Environment variable**: DEFAULT_PARAMS.UNIX_FILENAME.TYPES | File type allowed. | •&nbsp;file<br/>&nbsp;directory | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique`<br/>**Choices**: <br/>&nbsp;file<br/>&nbsp;directory |
### IP
> [!NOTE]
>
> **Path**: default_params.ip\
> `standard`
| Variable | Description | Default value | Type | Access control |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------|-----------------|-------------------------------------------------------------------------------------|------------------|
| **<a id="default_params.ip.private_only" name="default_params.ip.private_only">default_params.ip.private_only</a>**<br/>**Command line**: <br/>&nbsp;--default_params.ip.private_only<br/>&nbsp;--default_params.ip.no-private_only<br/>**Environment variable**: DEFAULT_PARAMS.IP.PRIVATE_ONLY | Private IP are allowed. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.ip.allow_reserved" name="default_params.ip.allow_reserved">default_params.ip.allow_reserved</a>**<br/>**Command line**: <br/>&nbsp;--default_params.ip.allow_reserved<br/>&nbsp;--default_params.ip.no-allow_reserved<br/>**Environment variable**: DEFAULT_PARAMS.IP.ALLOW_RESERVED | Reserved IP are allowed. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.ip.cidr" name="default_params.ip.cidr">default_params.ip.cidr</a>**<br/>**Command line**: <br/>&nbsp;--default_params.ip.cidr<br/>&nbsp;--default_params.ip.no-cidr<br/>**Environment variable**: DEFAULT_PARAMS.IP.CIDR | IP must be in CIDR format. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
### CIDR
> [!NOTE]
>
> **Path**: default_params.cidr\
> `standard`
| Variable | Description | Default value | Type | Access control |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------|-----------------|-------------------------------------------------------------------------------------|------------------|
| **<a id="default_params.cidr.private_only" name="default_params.cidr.private_only">default_params.cidr.private_only</a>**<br/>**Command line**: <br/>&nbsp;--default_params.cidr.private_only<br/>&nbsp;--default_params.cidr.no-private_only<br/>**Environment variable**: DEFAULT_PARAMS.CIDR.PRIVATE_ONLY | Private IP are allowed. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.cidr.allow_reserved" name="default_params.cidr.allow_reserved">default_params.cidr.allow_reserved</a>**<br/>**Command line**: <br/>&nbsp;--default_params.cidr.allow_reserved<br/>&nbsp;--default_params.cidr.no-allow_reserved<br/>**Environment variable**: DEFAULT_PARAMS.CIDR.ALLOW_RESERVED | Reserved IP are allowed. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.cidr.cidr" name="default_params.cidr.cidr">default_params.cidr.cidr</a>**<br/>**Command line**: <br/>&nbsp;--default_params.cidr.cidr<br/>&nbsp;--default_params.cidr.no-cidr<br/>**Environment variable**: DEFAULT_PARAMS.CIDR.CIDR | IP must be in CIDR format. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
### Network
> [!NOTE]
>
> **Path**: default_params.network\
> `standard`
| Variable | Description | Default value | Type | Access control |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------|-----------------|-------------------------------------------------------------------------------------|------------------|
| **<a id="default_params.network.private_only" name="default_params.network.private_only">default_params.network.private_only</a>**<br/>**Command line**: <br/>&nbsp;--default_params.network.private_only<br/>&nbsp;--default_params.network.no-private_only<br/>**Environment variable**: DEFAULT_PARAMS.NETWORK.PRIVATE_ONLY | Private network are allowed. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.network.allow_reserved" name="default_params.network.allow_reserved">default_params.network.allow_reserved</a>**<br/>**Command line**: <br/>&nbsp;--default_params.network.allow_reserved<br/>&nbsp;--default_params.network.no-allow_reserved<br/>**Environment variable**: DEFAULT_PARAMS.NETWORK.ALLOW_RESERVED | Reserved network are allowed. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.network.cidr" name="default_params.network.cidr">default_params.network.cidr</a>**<br/>**Command line**: <br/>&nbsp;--default_params.network.cidr<br/>&nbsp;--default_params.network.no-cidr<br/>**Environment variable**: DEFAULT_PARAMS.NETWORK.CIDR | Network must be in CIDR format. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
### Network CIDR
> [!NOTE]
>
> **Path**: default_params.network_cidr\
> `standard`
| Variable | Description | Default value | Type | Access control |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------|-----------------|-------------------------------------------------------------------------------------|------------------|
| **<a id="default_params.network_cidr.private_only" name="default_params.network_cidr.private_only">default_params.network_cidr.private_only</a>**<br/>**Command line**: <br/>&nbsp;--default_params.network_cidr.private_only<br/>&nbsp;--default_params.network_cidr.no-private_only<br/>**Environment variable**: DEFAULT_PARAMS.NETWORK_CIDR.PRIVATE_ONLY | Private network are allowed. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.network_cidr.allow_reserved" name="default_params.network_cidr.allow_reserved">default_params.network_cidr.allow_reserved</a>**<br/>**Command line**: <br/>&nbsp;--default_params.network_cidr.allow_reserved<br/>&nbsp;--default_params.network_cidr.no-allow_reserved<br/>**Environment variable**: DEFAULT_PARAMS.NETWORK_CIDR.ALLOW_RESERVED | Reserved network are allowed. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.network_cidr.cidr" name="default_params.network_cidr.cidr">default_params.network_cidr.cidr</a>**<br/>**Command line**: <br/>&nbsp;--default_params.network_cidr.cidr<br/>&nbsp;--default_params.network_cidr.no-cidr<br/>**Environment variable**: DEFAULT_PARAMS.NETWORK_CIDR.CIDR | Network must be in CIDR format. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
### Netbios
> [!NOTE]
>
> **Path**: default_params.netbios\
> `standard`
| Variable | Description | Default value | Type | Access control | Validator |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------|-----------------|-------------------------------------------------------------------------------------|------------------|--------------------------------------------------------------------------------------------|
| **<a id="default_params.netbios.type" name="default_params.netbios.type">default_params.netbios.type</a>**<br/>**Command line**: --default_params.netbios.type<br/>**Environment variable**: DEFAULT_PARAMS.NETBIOS.TYPE | Type of domainname. | netbios | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choices**: <br/>&nbsp;domainname<br/>&nbsp;netbios<br/>&nbsp;hostname<br/>&nbsp;null |
| **<a id="default_params.netbios.allow_without_dot" name="default_params.netbios.allow_without_dot">default_params.netbios.allow_without_dot</a>**<br/>**Command line**: <br/>&nbsp;--default_params.netbios.allow_without_dot<br/>&nbsp;--default_params.netbios.no-allow_without_dot<br/>**Environment variable**: DEFAULT_PARAMS.NETBIOS.ALLOW_WITHOUT_DOT | The domain name can be a hostname. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.netbios.test_existence" name="default_params.netbios.test_existence">default_params.netbios.test_existence</a>**<br/>**Command line**: <br/>&nbsp;--default_params.netbios.test_existence<br/>&nbsp;--default_params.netbios.no-test_existence<br/>**Environment variable**: DEFAULT_PARAMS.NETBIOS.TEST_EXISTENCE | The domain name must exist. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.netbios.allow_ip" name="default_params.netbios.allow_ip">default_params.netbios.allow_ip</a>**<br/>**Command line**: <br/>&nbsp;--default_params.netbios.allow_ip<br/>&nbsp;--default_params.netbios.no-allow_ip<br/>**Environment variable**: DEFAULT_PARAMS.NETBIOS.ALLOW_IP | The domain name can be an IP. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.netbios.allow_cidr_network" name="default_params.netbios.allow_cidr_network">default_params.netbios.allow_cidr_network</a>**<br/>**Command line**: <br/>&nbsp;--default_params.netbios.allow_cidr_network<br/>&nbsp;--default_params.netbios.no-allow_cidr_network<br/>**Environment variable**: DEFAULT_PARAMS.NETBIOS.ALLOW_CIDR_NETWORK | The domain name can be network in CIDR format. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.netbios.allow_startswith_dot" name="default_params.netbios.allow_startswith_dot">default_params.netbios.allow_startswith_dot</a>**<br/>**Command line**: <br/>&nbsp;--default_params.netbios.allow_startswith_dot<br/>&nbsp;--default_params.netbios.no-allow_startswith_dot<br/>**Environment variable**: DEFAULT_PARAMS.NETBIOS.ALLOW_STARTSWITH_DOT | The domain name can starts by a dot. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
### Domainname
> [!NOTE]
>
> **Path**: default_params.domainname\
> `standard`
| Variable | Description | Default value | Type | Access control | Validator |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------|-----------------|-------------------------------------------------------------------------------------|------------------|--------------------------------------------------------------------------------------------|
| **<a id="default_params.domainname.type" name="default_params.domainname.type">default_params.domainname.type</a>**<br/>**Command line**: --default_params.domainname.type<br/>**Environment variable**: DEFAULT_PARAMS.DOMAINNAME.TYPE | Type of domainname. | domainname | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choices**: <br/>&nbsp;domainname<br/>&nbsp;netbios<br/>&nbsp;hostname<br/>&nbsp;null |
| **<a id="default_params.domainname.allow_without_dot" name="default_params.domainname.allow_without_dot">default_params.domainname.allow_without_dot</a>**<br/>**Command line**: <br/>&nbsp;--default_params.domainname.allow_without_dot<br/>&nbsp;--default_params.domainname.no-allow_without_dot<br/>**Environment variable**: DEFAULT_PARAMS.DOMAINNAME.ALLOW_WITHOUT_DOT | The domain name can be a hostname. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.domainname.test_existence" name="default_params.domainname.test_existence">default_params.domainname.test_existence</a>**<br/>**Command line**: <br/>&nbsp;--default_params.domainname.test_existence<br/>&nbsp;--default_params.domainname.no-test_existence<br/>**Environment variable**: DEFAULT_PARAMS.DOMAINNAME.TEST_EXISTENCE | The domain name must exist. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.domainname.allow_ip" name="default_params.domainname.allow_ip">default_params.domainname.allow_ip</a>**<br/>**Command line**: <br/>&nbsp;--default_params.domainname.allow_ip<br/>&nbsp;--default_params.domainname.no-allow_ip<br/>**Environment variable**: DEFAULT_PARAMS.DOMAINNAME.ALLOW_IP | The domain name can be an IP. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.domainname.allow_cidr_network" name="default_params.domainname.allow_cidr_network">default_params.domainname.allow_cidr_network</a>**<br/>**Command line**: <br/>&nbsp;--default_params.domainname.allow_cidr_network<br/>&nbsp;--default_params.domainname.no-allow_cidr_network<br/>**Environment variable**: DEFAULT_PARAMS.DOMAINNAME.ALLOW_CIDR_NETWORK | The domain name can be network in CIDR format. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.domainname.allow_startswith_dot" name="default_params.domainname.allow_startswith_dot">default_params.domainname.allow_startswith_dot</a>**<br/>**Command line**: <br/>&nbsp;--default_params.domainname.allow_startswith_dot<br/>&nbsp;--default_params.domainname.no-allow_startswith_dot<br/>**Environment variable**: DEFAULT_PARAMS.DOMAINNAME.ALLOW_STARTSWITH_DOT | The domain name can starts by a dot. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
### Hostname
> [!NOTE]
>
> **Path**: default_params.hostname\
> `standard`
| Variable | Description | Default value | Type | Access control | Validator |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------|-----------------|-------------------------------------------------------------------------------------|------------------|--------------------------------------------------------------------------------------------|
| **<a id="default_params.hostname.type" name="default_params.hostname.type">default_params.hostname.type</a>**<br/>**Command line**: --default_params.hostname.type<br/>**Environment variable**: DEFAULT_PARAMS.HOSTNAME.TYPE | Type of domainname. | hostname | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choices**: <br/>&nbsp;domainname<br/>&nbsp;netbios<br/>&nbsp;hostname<br/>&nbsp;null |
| **<a id="default_params.hostname.allow_without_dot" name="default_params.hostname.allow_without_dot">default_params.hostname.allow_without_dot</a>**<br/>**Command line**: <br/>&nbsp;--default_params.hostname.allow_without_dot<br/>&nbsp;--default_params.hostname.no-allow_without_dot<br/>**Environment variable**: DEFAULT_PARAMS.HOSTNAME.ALLOW_WITHOUT_DOT | The domain name can be a hostname. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.hostname.test_existence" name="default_params.hostname.test_existence">default_params.hostname.test_existence</a>**<br/>**Command line**: <br/>&nbsp;--default_params.hostname.test_existence<br/>&nbsp;--default_params.hostname.no-test_existence<br/>**Environment variable**: DEFAULT_PARAMS.HOSTNAME.TEST_EXISTENCE | The domain name must exist. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.hostname.allow_ip" name="default_params.hostname.allow_ip">default_params.hostname.allow_ip</a>**<br/>**Command line**: <br/>&nbsp;--default_params.hostname.allow_ip<br/>&nbsp;--default_params.hostname.no-allow_ip<br/>**Environment variable**: DEFAULT_PARAMS.HOSTNAME.ALLOW_IP | The domain name can be an IP. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.hostname.allow_cidr_network" name="default_params.hostname.allow_cidr_network">default_params.hostname.allow_cidr_network</a>**<br/>**Command line**: <br/>&nbsp;--default_params.hostname.allow_cidr_network<br/>&nbsp;--default_params.hostname.no-allow_cidr_network<br/>**Environment variable**: DEFAULT_PARAMS.HOSTNAME.ALLOW_CIDR_NETWORK | The domain name can be network in CIDR format. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.hostname.allow_startswith_dot" name="default_params.hostname.allow_startswith_dot">default_params.hostname.allow_startswith_dot</a>**<br/>**Command line**: <br/>&nbsp;--default_params.hostname.allow_startswith_dot<br/>&nbsp;--default_params.hostname.no-allow_startswith_dot<br/>**Environment variable**: DEFAULT_PARAMS.HOSTNAME.ALLOW_STARTSWITH_DOT | The domain name can starts by a dot. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
### Web address
> [!NOTE]
>
> **Path**: default_params.web_address\
> `standard`
| Variable | Description | Default value | Type | Access control | Validator |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------|-----------------|-------------------------------------------------------------------------------------|------------------|--------------------------------------------------------------------------------------------|
| **<a id="default_params.web_address.type" name="default_params.web_address.type">default_params.web_address.type</a>**<br/>**Command line**: --default_params.web_address.type<br/>**Environment variable**: DEFAULT_PARAMS.WEB_ADDRESS.TYPE | Type of domainname. | domainname | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choices**: <br/>&nbsp;domainname<br/>&nbsp;netbios<br/>&nbsp;hostname<br/>&nbsp;null |
| **<a id="default_params.web_address.allow_without_dot" name="default_params.web_address.allow_without_dot">default_params.web_address.allow_without_dot</a>**<br/>**Command line**: <br/>&nbsp;--default_params.web_address.allow_without_dot<br/>&nbsp;--default_params.web_address.no-allow_without_dot<br/>**Environment variable**: DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_WITHOUT_DOT | The domain name can be a hostname. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.test_existence" name="default_params.web_address.test_existence">default_params.web_address.test_existence</a>**<br/>**Command line**: <br/>&nbsp;--default_params.web_address.test_existence<br/>&nbsp;--default_params.web_address.no-test_existence<br/>**Environment variable**: DEFAULT_PARAMS.WEB_ADDRESS.TEST_EXISTENCE | The domain name must exist. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_ip" name="default_params.web_address.allow_ip">default_params.web_address.allow_ip</a>**<br/>**Command line**: <br/>&nbsp;--default_params.web_address.allow_ip<br/>&nbsp;--default_params.web_address.no-allow_ip<br/>**Environment variable**: DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_IP | The domain name can be an IP. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_cidr_network" name="default_params.web_address.allow_cidr_network">default_params.web_address.allow_cidr_network</a>**<br/>**Command line**: <br/>&nbsp;--default_params.web_address.allow_cidr_network<br/>&nbsp;--default_params.web_address.no-allow_cidr_network<br/>**Environment variable**: DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_CIDR_NETWORK | The domain name can be network in CIDR format. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_startswith_dot" name="default_params.web_address.allow_startswith_dot">default_params.web_address.allow_startswith_dot</a>**<br/>**Command line**: <br/>&nbsp;--default_params.web_address.allow_startswith_dot<br/>&nbsp;--default_params.web_address.no-allow_startswith_dot<br/>**Environment variable**: DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_STARTSWITH_DOT | The domain name can starts by a dot. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_range" name="default_params.web_address.allow_range">default_params.web_address.allow_range</a>**<br/>**Command line**: <br/>&nbsp;--default_params.web_address.allow_range<br/>&nbsp;--default_params.web_address.no-allow_range<br/>**Environment variable**: DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_RANGE | Can be range of port. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_protocol" name="default_params.web_address.allow_protocol">default_params.web_address.allow_protocol</a>**<br/>**Command line**: <br/>&nbsp;--default_params.web_address.allow_protocol<br/>&nbsp;--default_params.web_address.no-allow_protocol<br/>**Environment variable**: DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_PROTOCOL | Can have the protocol. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_zero" name="default_params.web_address.allow_zero">default_params.web_address.allow_zero</a>**<br/>**Command line**: <br/>&nbsp;--default_params.web_address.allow_zero<br/>&nbsp;--default_params.web_address.no-allow_zero<br/>**Environment variable**: DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_ZERO | Port 0 is allowed. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_wellknown" name="default_params.web_address.allow_wellknown">default_params.web_address.allow_wellknown</a>**<br/>**Command line**: <br/>&nbsp;--default_params.web_address.allow_wellknown<br/>&nbsp;--default_params.web_address.no-allow_wellknown<br/>**Environment variable**: DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_WELLKNOWN | Well-known ports (1 to 1023) are allowed. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_registred" name="default_params.web_address.allow_registred">default_params.web_address.allow_registred</a>**<br/>**Command line**: <br/>&nbsp;--default_params.web_address.allow_registred<br/>&nbsp;--default_params.web_address.no-allow_registred<br/>**Environment variable**: DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_REGISTRED | Registred ports (1024 to 49151) are allowed. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
| **<a id="default_params.web_address.allow_private" name="default_params.web_address.allow_private">default_params.web_address.allow_private</a>**<br/>**Command line**: <br/>&nbsp;--default_params.web_address.allow_private<br/>&nbsp;--default_params.web_address.no-allow_private<br/>**Environment variable**: DEFAULT_PARAMS.WEB_ADDRESS.ALLOW_PRIVATE | Private ports (greater than 49152) are allowed. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | |
### Port
> [!NOTE]
>
> **Path**: default_params.port\
> `standard`
| Variable | Description | Default value | Type | Access control |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------|-----------------|-------------------------------------------------------------------------------------|------------------|
| **<a id="default_params.port.allow_range" name="default_params.port.allow_range">default_params.port.allow_range</a>**<br/>**Command line**: <br/>&nbsp;--default_params.port.allow_range<br/>&nbsp;--default_params.port.no-allow_range<br/>**Environment variable**: DEFAULT_PARAMS.PORT.ALLOW_RANGE | Can be range of port. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.port.allow_protocol" name="default_params.port.allow_protocol">default_params.port.allow_protocol</a>**<br/>**Command line**: <br/>&nbsp;--default_params.port.allow_protocol<br/>&nbsp;--default_params.port.no-allow_protocol<br/>**Environment variable**: DEFAULT_PARAMS.PORT.ALLOW_PROTOCOL | Can have the protocol. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.port.allow_zero" name="default_params.port.allow_zero">default_params.port.allow_zero</a>**<br/>**Command line**: <br/>&nbsp;--default_params.port.allow_zero<br/>&nbsp;--default_params.port.no-allow_zero<br/>**Environment variable**: DEFAULT_PARAMS.PORT.ALLOW_ZERO | Port 0 is allowed. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.port.allow_wellknown" name="default_params.port.allow_wellknown">default_params.port.allow_wellknown</a>**<br/>**Command line**: <br/>&nbsp;--default_params.port.allow_wellknown<br/>&nbsp;--default_params.port.no-allow_wellknown<br/>**Environment variable**: DEFAULT_PARAMS.PORT.ALLOW_WELLKNOWN | Well-known ports (1 to 1023) are allowed. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.port.allow_registred" name="default_params.port.allow_registred">default_params.port.allow_registred</a>**<br/>**Command line**: <br/>&nbsp;--default_params.port.allow_registred<br/>&nbsp;--default_params.port.no-allow_registred<br/>**Environment variable**: DEFAULT_PARAMS.PORT.ALLOW_REGISTRED | Registred ports (1024 to 49151) are allowed. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
| **<a id="default_params.port.allow_private" name="default_params.port.allow_private">default_params.port.allow_private</a>**<br/>**Command line**: <br/>&nbsp;--default_params.port.allow_private<br/>&nbsp;--default_params.port.no-allow_private<br/>**Environment variable**: DEFAULT_PARAMS.PORT.ALLOW_PRIVATE | Private ports (greater than 49152) are allowed. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` |
Use [Tiramisu](https://framagit.org/tiramisu/tiramisu) API to change values:
```python
from rougail import Rougail, RougailConfig
from pprint import pprint
RougailConfig['dictionaries_dir'] = ['dict']
rougail = Rougail()
config = rougail.get_config()
config.option('rougail.my_first_variable').value.set('modified_value')
config.option('rougail.my_family.my_second_variable').value.set(2)
pprint(config.value.get(), sort_dicts=False)
```
The destination file is generated with new values:
```json
{<TiramisuOption path="rougail">: {<TiramisuOption path="rougail.my_first_variable">: 'modified_value',
<TiramisuOption path="rougail.my_family">: {<TiramisuOption path="rougail.my_family.my_second_variable">: 2}}}
```
# Link
* [Documentation](https://rougail.readthedocs.io/en/latest/)
* [Licence ](LICENSE)
# Related projects
* [Tiramisu](https://forge.cloud.silique.fr/gnunux/tiramisu)
* [Risotto](https://cloud.silique.fr/gitea/risotto/risotto)

View file

@ -5,8 +5,8 @@
msgid "" msgid ""
msgstr "" msgstr ""
"Project-Id-Version: \n" "Project-Id-Version: \n"
"POT-Creation-Date: 2025-11-21 08:31+0100\n" "POT-Creation-Date: 2025-12-22 08:45+0100\n"
"PO-Revision-Date: 2025-11-21 08:31+0100\n" "PO-Revision-Date: 2025-12-22 08:46+0100\n"
"Last-Translator: \n" "Last-Translator: \n"
"Language-Team: \n" "Language-Team: \n"
"Language: fr\n" "Language: fr\n"
@ -185,79 +185,146 @@ msgid ""
msgstr "" msgstr ""
"la variable \"{0}\" a la valeur par défaut invalide \"{1}\" devrait être {2}" "la variable \"{0}\" a la valeur par défaut invalide \"{1}\" devrait être {2}"
#: src/rougail/config/__init__.py:276 #: src/rougail/config/__init__.py:271
msgid "Structure format version by default, if not specified in structure file" msgid "Default version of the structural file format"
msgstr "Version par défaut du format des fichiers de structure"
#: src/rougail/config/__init__.py:272
msgid ""
"This value is only used if the version is not set in the structural file"
msgstr "" msgstr ""
"La version du format de la structure par défaut, si non spécifier dans le " "Cette valeur n'est utilisée que si la version n'est pas définie dans le "
"fichier de structure" "fichier de structure"
#: src/rougail/config/__init__.py:284 #: src/rougail/config/__init__.py:280
msgid "File with functions" msgid "File with functions"
msgstr "Fichier avec les fonctions" msgstr "Fichier avec les fonctions"
#: src/rougail/config/__init__.py:296 #: src/rougail/config/__init__.py:281
msgid ""
"This file contains filters and additional Jinja2 functions usable in "
"structure files"
msgstr ""
"Ce fichier contient des filtres et des fonctions Jinja2 supplémentaires "
"utilisables dans les fichiers de structure"
#: src/rougail/config/__init__.py:293
msgid "All modes level available" msgid "All modes level available"
msgstr "Tous les niveaux de modes valides" msgstr "Tous les niveaux de modes valides"
#: src/rougail/config/__init__.py:308 #: src/rougail/config/__init__.py:305
msgid "Default mode for a family" msgid "Default mode for a family"
msgstr "Mode par défaut pour une famille" msgstr "Mode par défaut pour une famille"
#: src/rougail/config/__init__.py:311
msgid "the first one defined in \"modes_level\""
msgstr "le premier défini dans \"modes_level\""
#: src/rougail/config/__init__.py:317 src/rougail/config/__init__.py:344
msgid "when no mode is defined in \"modes_level\""
msgstr "si aucun mode n'est défini dans \"modes_level\""
#: src/rougail/config/__init__.py:324 src/rougail/config/__init__.py:351
msgid "this mode must be available in \"modes_level\""
msgstr "ce mode doit être disponible dans \"modes_level\""
#: src/rougail/config/__init__.py:328 #: src/rougail/config/__init__.py:328
msgid "Default mode for a variable" msgid "Default mode for a variable"
msgstr "Mode par défaut pour une variable" msgstr "Mode par défaut pour une variable"
#: src/rougail/config/__init__.py:352 #: src/rougail/config/__init__.py:338
msgid ""
"if the variable \"modes_level\" is defined, the default value is the second "
"available element, otherwise, the first"
msgstr ""
"si la variable \"modes_level\" est définit, la valeur par défaut est le "
"second élément disponible, sinon, le premier"
#: src/rougail/config/__init__.py:355
msgid "Option name for the base option" msgid "Option name for the base option"
msgstr "Nom de l'option pour l'option de base" msgstr "Nom de l'option pour l'option de base"
#: src/rougail/config/__init__.py:357 #: src/rougail/config/__init__.py:360
msgid "In cache file, do not importation of Tiramisu and other dependencies" msgid "In cache file, do not importation of Tiramisu and other dependencies"
msgstr "" msgstr ""
"Dans le fichier de cache, ne pas importer Tiramisu et autres dépendances" "Dans le fichier de cache, ne pas importer Tiramisu et autres dépendances"
#: src/rougail/config/__init__.py:362 #: src/rougail/config/__init__.py:365
msgid "Tiramisu cache filename" #, fuzzy
msgstr "Nom du fichier du cache Tiramisu" #| msgid "Store tiramisu cache filename"
msgid "Store Tiramisu cache filename"
msgstr "Enregistrer le cache Tiramisu dans le fichier"
#: src/rougail/config/__init__.py:370 #: src/rougail/config/__init__.py:366
msgid ""
"This file contains the Tiramisu instructions used internally to load the "
"variables.\n"
"\n"
"This file can be used for debugging"
msgstr ""
"Ce fichier contient les instructions Tiramisu utilisé en interne pour "
"charger les variables.\n"
"\n"
"Ce fichier peut être utilisé pour le débogage."
#: src/rougail/config/__init__.py:376
msgid "Name of internal functions that we can use as a function" msgid "Name of internal functions that we can use as a function"
msgstr "" msgstr ""
"Nom des fonctions internes qu'il est possible d'utiliser comme fonction" "Nom des fonctions internes qu'il est possible d'utiliser comme fonction"
#: src/rougail/config/__init__.py:376 #: src/rougail/config/__init__.py:382
msgid "Name of extra annotators" msgid "Name of extra annotators"
msgstr "Nom des annotators supplémentaires" msgstr "Nom des annotators supplémentaires"
#: src/rougail/config/__init__.py:382 #: src/rougail/config/__init__.py:388
msgid "Suffix add to generated options name" msgid "Suffix add to generated options name"
msgstr "Suffix ajouté pour généré le nom des options" msgstr "Suffix ajouté pour généré le nom des options"
#: src/rougail/config/__init__.py:388 #: src/rougail/config/__init__.py:394
msgid "Every variables in calculation are optionals" msgid "Every variables in calculation are optionals"
msgstr "Toutes les variables dans un calcul sont optionnelles" msgstr "Toutes les variables dans un calcul sont optionnelles"
#: src/rougail/config/__init__.py:392 #: src/rougail/config/__init__.py:398
msgid "Loads redefine variables even if there don't already exists" msgid "Loads redefine variables even if there don't already exists"
msgstr "Charger les variables redéfinis même si elles n'existe pas" msgstr "Charger les variables redéfinis même si elles n'existe pas"
#: src/rougail/config/__init__.py:399 #: src/rougail/config/__init__.py:402
msgid "The secret pattern to build item name in Bitwarden" msgid "The secret manager"
msgstr "Le patron de secret pour construire le nom de l'élément dans Bitwarden" msgstr "Le gestionnaire de secret"
#: src/rougail/config/__init__.py:400 #: src/rougail/config/__init__.py:405
msgid "The pattern is in Jinja format" msgid ""
msgstr "Le patron est au format Jinja" "The secret pattern to constructing the name of the item searched for in the "
"secret manager"
msgstr ""
"Le modèle de secret permettant de construire le nom de l'élément recherché "
"dans le gestionnaire de secrets"
#: src/rougail/config/__init__.py:428 #: src/rougail/config/__init__.py:406
msgid "The pattern is in Jinja2 format"
msgstr "Le modèle est au format Jinja2"
#: src/rougail/config/__init__.py:415
msgid "structural"
msgstr "structure"
#: src/rougail/config/__init__.py:416
msgid "user datas"
msgstr "données utilisateur"
#: src/rougail/config/__init__.py:417
msgid "output"
msgstr "sortie"
#: src/rougail/config/__init__.py:438
msgid "Select for {0}" msgid "Select for {0}"
msgstr "Sélection pour {0}" msgstr "Sélection pour {0}"
#: src/rougail/config/__init__.py:508 #: src/rougail/config/__init__.py:500
msgid "Override default parameters for option type" msgid "Override default parameters for option type"
msgstr "Sur charger les paramètre par défaut pour le type d'option" msgstr "Sur charger les paramètre par défaut pour le type d'option"
#: src/rougail/config/__init__.py:511 #: src/rougail/config/__init__.py:503
msgid "Default parameters for option type" msgid "Default parameters for option type"
msgstr "Paramètre par défaut pour le type d'option" msgstr "Paramètre par défaut pour le type d'option"
@ -296,42 +363,42 @@ msgstr ""
"définition invalide pour la définition des \"structures\" ({0}), aucun " "définition invalide pour la définition des \"structures\" ({0}), aucun "
"fichier de structure ne peut être chargé !" "fichier de structure ne peut être chargé !"
#: src/rougail/convert/object_model.py:121 #: src/rougail/convert/object_model.py:132
msgid "cannot find variable \"{0}\" defined in attribute \"{1}\" for \"{2}\"" msgid "cannot find variable \"{0}\" defined in attribute \"{1}\" for \"{2}\""
msgstr "" msgstr ""
"ne peut trouver la variable \"{0}\" défini dans l'attribut \"{1}\" pour " "ne peut trouver la variable \"{0}\" défini dans l'attribut \"{1}\" pour "
"\"{2}\"" "\"{2}\""
#: src/rougail/convert/object_model.py:127 #: src/rougail/convert/object_model.py:138
msgid "" msgid ""
"the variable \"{0}\" is in fact a family in attribute \"{1}\" for \"{2}\"" "the variable \"{0}\" is in fact a family in attribute \"{1}\" for \"{2}\""
msgstr "" msgstr ""
"la variable \"{0}\" est en faite une famille dans l'attribut \"{1}\" pour " "la variable \"{0}\" est en faite une famille dans l'attribut \"{1}\" pour "
"\"{2}\"" "\"{2}\""
#: src/rougail/convert/object_model.py:132 #: src/rougail/convert/object_model.py:143
#: src/rougail/convert/object_model.py:513 #: src/rougail/convert/object_model.py:527
msgid "unknown object \"{0}\" in attribute \"{1}\" for \"{2}\"" msgid "unknown object \"{0}\" in attribute \"{1}\" for \"{2}\""
msgstr "objet inconnu \"{0}\" dans l'attribut \"{1}\" pour \"{2}\"" msgstr "objet inconnu \"{0}\" dans l'attribut \"{1}\" pour \"{2}\""
#: src/rougail/convert/object_model.py:151 #: src/rougail/convert/object_model.py:162
msgid "" msgid ""
"identifier parameter for \"{0}\" in \"{1}\" cannot be set none dynamic family" "identifier parameter for \"{0}\" in \"{1}\" cannot be set none dynamic family"
msgstr "" msgstr ""
"le paramètre identifier pour \"{0}\" dans \"{1}\" ne peut être placé pour " "le paramètre identifier pour \"{0}\" dans \"{1}\" ne peut être placé pour "
"une famille non dynamique" "une famille non dynamique"
#: src/rougail/convert/object_model.py:180 #: src/rougail/convert/object_model.py:191
msgid "cannot find variable \"{0}\" defined in \"{1}\" for \"{2}\"" msgid "cannot find variable \"{0}\" defined in \"{1}\" for \"{2}\""
msgstr "ne peut trouver la variable \"{0}\" défini dans \"{1}\" pour \"{2}\"" msgstr "ne peut trouver la variable \"{0}\" défini dans \"{1}\" pour \"{2}\""
#: src/rougail/convert/object_model.py:185 #: src/rougail/convert/object_model.py:196
msgid "variable \"{0}\" defined in \"{1}\" for \"{2}\" is a dynamic variable" msgid "variable \"{0}\" defined in \"{1}\" for \"{2}\" is a dynamic variable"
msgstr "" msgstr ""
"la variable \"{0}\" défini dans \"{1}\" pour \"{2}\" est une variable " "la variable \"{0}\" défini dans \"{1}\" pour \"{2}\" est une variable "
"dynamique" "dynamique"
#: src/rougail/convert/object_model.py:202 #: src/rougail/convert/object_model.py:213
msgid "" msgid ""
"the variable \"{0}\" is not a follower, so cannot have index type for param " "the variable \"{0}\" is not a follower, so cannot have index type for param "
"in \"{1}\"" "in \"{1}\""
@ -339,7 +406,7 @@ msgstr ""
"la variable \"{0}\" n'est pas suiveuse, donc ne peut avoir de type index " "la variable \"{0}\" n'est pas suiveuse, donc ne peut avoir de type index "
"comme paramètre dans \"{1}\"" "comme paramètre dans \"{1}\""
#: src/rougail/convert/object_model.py:252 #: src/rougail/convert/object_model.py:263
msgid "" msgid ""
"\"warnings\" are only available with attribute \"{self.attribute_name}\" for " "\"warnings\" are only available with attribute \"{self.attribute_name}\" for "
"variable \"{self.ori_path}\"" "variable \"{self.ori_path}\""
@ -347,16 +414,16 @@ msgstr ""
"\"warnings\" est seulement utilisable avec l'attribut \"{self.attribute_name}" "\"warnings\" est seulement utilisable avec l'attribut \"{self.attribute_name}"
"\" pour la variable \"{self.ori_path}\"" "\" pour la variable \"{self.ori_path}\""
#: src/rougail/convert/object_model.py:314 #: src/rougail/convert/object_model.py:325
msgid "" msgid ""
"the variable \"{0}\" has a depreciated return_type \"{1}\", please use " "the variable \"{0}\" has a depreciated return_type \"{1}\", please use "
"\"{2}\" instead in \"{3}\"" "\"{2}\" instead in {3}"
msgstr "" msgstr ""
"la variable \"{0}\" a un attribut return_type déprécié \"{1}\", veuillez " "la variable \"{0}\" a un attribut return_type déprécié \"{1}\", veuillez "
"utiliser\"{2}\" au lieu de \"{3}\"" "utiliser \"{2}\" au lieu de \"{3}\""
#: src/rougail/convert/object_model.py:404 #: src/rougail/convert/object_model.py:415
#: src/rougail/convert/object_model.py:435 #: src/rougail/convert/object_model.py:446
msgid "" msgid ""
"variable \"{0}\" has a calculating \"{1}\" with an invalid return_type, " "variable \"{0}\" has a calculating \"{1}\" with an invalid return_type, "
"should be boolean or string, not \"{2}\"" "should be boolean or string, not \"{2}\""
@ -364,7 +431,7 @@ msgstr ""
"la variable \"{0}\" a un calcul \"{1}\" avec un return_type invalide, " "la variable \"{0}\" a un calcul \"{1}\" avec un return_type invalide, "
"devrait être un booléen ou une chaîne de caractère, et pas \"{2}\"" "devrait être un booléen ou une chaîne de caractère, et pas \"{2}\""
#: src/rougail/convert/object_model.py:411 #: src/rougail/convert/object_model.py:422
msgid "" msgid ""
"the variable \"{0}\" has a return_type \"{1}\", for attribute \"{2}\" but " "the variable \"{0}\" has a return_type \"{1}\", for attribute \"{2}\" but "
"has not description in {3}" "has not description in {3}"
@ -372,11 +439,11 @@ msgstr ""
"la variable \"{0}\" a un return_type \"{1}\", pour l'attribut \"{2}\" mais " "la variable \"{0}\" a un return_type \"{1}\", pour l'attribut \"{2}\" mais "
"n'a pas de description dans {3}" "n'a pas de description dans {3}"
#: src/rougail/convert/object_model.py:416 #: src/rougail/convert/object_model.py:427
msgid "value is invalid" msgid "value is invalid"
msgstr "la valeur est invalide" msgstr "la valeur est invalide"
#: src/rougail/convert/object_model.py:508 #: src/rougail/convert/object_model.py:522
msgid "" msgid ""
"a variable \"{0}\" is needs in attribute \"{1}\" for \"{2}\" but it's a " "a variable \"{0}\" is needs in attribute \"{1}\" for \"{2}\" but it's a "
"family" "family"
@ -384,7 +451,7 @@ msgstr ""
"une variable \"{0}\" est nécessaire pour l'attribut \"{1}\" pour \"{2}\" " "une variable \"{0}\" est nécessaire pour l'attribut \"{1}\" pour \"{2}\" "
"mais c'est une famille" "mais c'est une famille"
#: src/rougail/convert/object_model.py:533 #: src/rougail/convert/object_model.py:547
msgid "" msgid ""
"variable \"{0}\" has an attribute \"{1}\" calculated with the unknown " "variable \"{0}\" has an attribute \"{1}\" calculated with the unknown "
"variable \"{2}\"" "variable \"{2}\""
@ -392,7 +459,7 @@ msgstr ""
"la variable \"{0}\" a un attribut invalide \"{1}\" calculé avec la variable " "la variable \"{0}\" a un attribut invalide \"{1}\" calculé avec la variable "
"inconnue \"{2}\"" "inconnue \"{2}\""
#: src/rougail/convert/object_model.py:585 #: src/rougail/convert/object_model.py:599
msgid "" msgid ""
"the variable \"{0}\" has an invalid \"{1}\" the variable \"{2}\" is in a sub " "the variable \"{0}\" has an invalid \"{1}\" the variable \"{2}\" is in a sub "
"dynamic option" "dynamic option"
@ -400,14 +467,14 @@ msgstr ""
"la variable \"{0}\" a un attribut invalide \"{1}\", la variable \"{2}\" est " "la variable \"{0}\" a un attribut invalide \"{1}\", la variable \"{2}\" est "
"dans une sous option dynamique" "dans une sous option dynamique"
#: src/rougail/convert/object_model.py:594 #: src/rougail/convert/object_model.py:608
msgid "" msgid ""
"the leader \"{0}\" has an invalid \"{1}\" the follower \"{2}\" is a multi" "the leader \"{0}\" has an invalid \"{1}\" the follower \"{2}\" is a multi"
msgstr "" msgstr ""
"la variable meneuse \"{0}\" a un attribut invalide \"{1}\", la variable " "la variable meneuse \"{0}\" a un attribut invalide \"{1}\", la variable "
"suiveuse \"{2}\" est multiple" "suiveuse \"{2}\" est multiple"
#: src/rougail/convert/object_model.py:636 #: src/rougail/convert/object_model.py:650
msgid "" msgid ""
"the variable \"{0}\" has an invalid attribute \"{1}\", the variable \"{2}\" " "the variable \"{0}\" has an invalid attribute \"{1}\", the variable \"{2}\" "
"must not be multi" "must not be multi"
@ -415,7 +482,7 @@ msgstr ""
"la variable \"{0}\" a un attribut invalide \"{1}\", la variable \"{2}\" ne " "la variable \"{0}\" a un attribut invalide \"{1}\", la variable \"{2}\" ne "
"doit pas être multiple" "doit pas être multiple"
#: src/rougail/convert/object_model.py:650 #: src/rougail/convert/object_model.py:664
msgid "" msgid ""
"the variable \"{0}\" has an invalid attribute \"{1}\", the variable must not " "the variable \"{0}\" has an invalid attribute \"{1}\", the variable must not "
"be a multi or the variable \"{2}\" must be multi" "be a multi or the variable \"{2}\" must be multi"
@ -423,7 +490,7 @@ msgstr ""
"la variable \"{0}\" a un attribut invalide \"{1}\", la variable ne doit pas " "la variable \"{0}\" a un attribut invalide \"{1}\", la variable ne doit pas "
"être multiple ou la variable \"{2}\" doit être multiple" "être multiple ou la variable \"{2}\" doit être multiple"
#: src/rougail/convert/object_model.py:664 #: src/rougail/convert/object_model.py:678
msgid "" msgid ""
"the variable \"{0}\" has an invalid attribute \"{1}\", the variable must be " "the variable \"{0}\" has an invalid attribute \"{1}\", the variable must be "
"a multi or the variable \"{2}\" must not be multi" "a multi or the variable \"{2}\" must not be multi"
@ -431,7 +498,7 @@ msgstr ""
"la variable \"{0}\" a un attribut invalide \"{1}\", la variable doit être " "la variable \"{0}\" a un attribut invalide \"{1}\", la variable doit être "
"multiple ou la variable \"{2}\" ne doit pas être multiple" "multiple ou la variable \"{2}\" ne doit pas être multiple"
#: src/rougail/convert/object_model.py:678 #: src/rougail/convert/object_model.py:692
msgid "" msgid ""
"the variable \"{0}\" has an invalid attribute \"{1}\", the variable \"{2}\" " "the variable \"{0}\" has an invalid attribute \"{1}\", the variable \"{2}\" "
"is multi but is inside a list" "is multi but is inside a list"
@ -439,7 +506,7 @@ msgstr ""
"la variable \"{0}\" a un attribut invalide \"{1}\", la variable \"{2}\" est " "la variable \"{0}\" a un attribut invalide \"{1}\", la variable \"{2}\" est "
"multiple mais est dans une liste" "multiple mais est dans une liste"
#: src/rougail/convert/object_model.py:700 #: src/rougail/convert/object_model.py:714
msgid "" msgid ""
"the variable \"{0}\" is waiting for a list as \"{1}\" but the attribute " "the variable \"{0}\" is waiting for a list as \"{1}\" but the attribute "
"\"default\" is not a list (\"{2}\")" "\"default\" is not a list (\"{2}\")"
@ -447,7 +514,7 @@ msgstr ""
"la variable \"{0}\" attend une liste comme \"{1}\" mais l'attribut " "la variable \"{0}\" attend une liste comme \"{1}\" mais l'attribut "
"\"default\" n'est pas une liste \"{2}\"" "\"default\" n'est pas une liste \"{2}\""
#: src/rougail/convert/object_model.py:704 #: src/rougail/convert/object_model.py:718
msgid "" msgid ""
"the variable \"{0}\" is not waiting for a list as \"{1}\" but the attribute " "the variable \"{0}\" is not waiting for a list as \"{1}\" but the attribute "
"\"default\" is a list (\"{2}\")" "\"default\" is a list (\"{2}\")"
@ -455,7 +522,7 @@ msgstr ""
"la variable \"{0}\" n'attend pas une liste comme \"{1}\" mais l'attribut " "la variable \"{0}\" n'attend pas une liste comme \"{1}\" mais l'attribut "
"\"default\" est une liste \"{2}\"" "\"default\" est une liste \"{2}\""
#: src/rougail/convert/object_model.py:726 #: src/rougail/convert/object_model.py:740
msgid "" msgid ""
"\"{0}\" attribut shall not have an \"optional\" attribute without the " "\"{0}\" attribut shall not have an \"optional\" attribute without the "
"\"default\" attribute for variable \"{1}\"" "\"default\" attribute for variable \"{1}\""
@ -463,7 +530,7 @@ msgstr ""
"l'attribut \"{0}\" ne devrait pas avoir d'attribut \"optional\" sans " "l'attribut \"{0}\" ne devrait pas avoir d'attribut \"optional\" sans "
"l'attribut \"default\" pour la variable \"{1}\"" "l'attribut \"default\" pour la variable \"{1}\""
#: src/rougail/convert/object_model.py:748 #: src/rougail/convert/object_model.py:762
msgid "" msgid ""
"variable \"{0}\" has a default value calculated with \"{1}\" which has " "variable \"{0}\" has a default value calculated with \"{1}\" which has "
"incompatible type" "incompatible type"
@ -471,7 +538,7 @@ msgstr ""
"la variable \"{0}\" a une valeur par défaut calculé a partir de \"{1}\" " "la variable \"{0}\" a une valeur par défaut calculé a partir de \"{1}\" "
"laquelle a un type incompatible" "laquelle a un type incompatible"
#: src/rougail/convert/object_model.py:790 #: src/rougail/convert/object_model.py:804
msgid "" msgid ""
"the variable \"{0}\" is waiting for a boolean as \"{1}\" but the attribute " "the variable \"{0}\" is waiting for a boolean as \"{1}\" but the attribute "
"\"default\" is not a boolean (\"{2}\")" "\"default\" is not a boolean (\"{2}\")"
@ -479,7 +546,7 @@ msgstr ""
"la variable \"{0}\" attend un booléan comme \"{1}\" mais l'attribut " "la variable \"{0}\" attend un booléan comme \"{1}\" mais l'attribut "
"\"default\" n'est pas une booléan (\"{2}\")" "\"default\" n'est pas une booléan (\"{2}\")"
#: src/rougail/convert/object_model.py:812 #: src/rougail/convert/object_model.py:826
msgid "" msgid ""
"\"when\" is not allowed in format version 1.0 for attribute \"{0}\" for " "\"when\" is not allowed in format version 1.0 for attribute \"{0}\" for "
"variable \"{1}\"" "variable \"{1}\""
@ -487,7 +554,7 @@ msgstr ""
"\"when\" n'est pas autorisé avec le format en version 1.0 pour l'attribut " "\"when\" n'est pas autorisé avec le format en version 1.0 pour l'attribut "
"\"{0}\" pour la variable \"{1}\"" "\"{0}\" pour la variable \"{1}\""
#: src/rougail/convert/object_model.py:817 #: src/rougail/convert/object_model.py:831
msgid "" msgid ""
"the variable \"{0}\" has an invalid attribute \"{1}\", \"when\" and " "the variable \"{0}\" has an invalid attribute \"{1}\", \"when\" and "
"\"when_not\" cannot set together" "\"when_not\" cannot set together"
@ -495,7 +562,7 @@ msgstr ""
"la variable \"{0}\" a un attribut invalide \"{1}\", \"when\" et \"when_not\" " "la variable \"{0}\" a un attribut invalide \"{1}\", \"when\" et \"when_not\" "
"ne peuvent pas être défini ensemble" "ne peuvent pas être défini ensemble"
#: src/rougail/convert/object_model.py:825 #: src/rougail/convert/object_model.py:839
msgid "" msgid ""
"\"when_not\" is not allowed in format version 1.0 for attribute \"{0}\" for " "\"when_not\" is not allowed in format version 1.0 for attribute \"{0}\" for "
"variable \"{1}\"" "variable \"{1}\""
@ -503,7 +570,15 @@ msgstr ""
"\"when_not\" n'est pas autorisé au format 1.0 pour l'attribut \"{0}\" pour " "\"when_not\" n'est pas autorisé au format 1.0 pour l'attribut \"{0}\" pour "
"la variable variable \"{1}\"" "la variable variable \"{1}\""
#: src/rougail/convert/object_model.py:881 #: src/rougail/convert/object_model.py:850
msgid ""
"\"when\" or \"when_not\" is mandatory for the not boolean variable \"{0}\" "
"in attribute \"{1}\""
msgstr ""
"\"when\" ou \"when_not\" est obligatoire pour la variable non booléenne "
"\"{0}\" dans l'attribut \"{1}\""
#: src/rougail/convert/object_model.py:898
msgid "" msgid ""
"cannot find variable \"{0}\" for the information \"{1}\" when calculating " "cannot find variable \"{0}\" for the information \"{1}\" when calculating "
"\"{2}\"" "\"{2}\""
@ -511,19 +586,19 @@ msgstr ""
"ne peut trouver la variable \"{0}\" pour l'information \"{1}\" lors du " "ne peut trouver la variable \"{0}\" pour l'information \"{1}\" lors du "
"calcul de \"{2}\"" "calcul de \"{2}\""
#: src/rougail/convert/object_model.py:886 #: src/rougail/convert/object_model.py:903
msgid "" msgid ""
"identifier not allowed for the information \"{0}\" when calculating \"{1}\"" "identifier not allowed for the information \"{0}\" when calculating \"{1}\""
msgstr "" msgstr ""
"identifier n'est pas autorisé pour l'information \"{0}\" lors du calcul de " "identifier n'est pas autorisé pour l'information \"{0}\" lors du calcul de "
"\"{1}\"" "\"{1}\""
#: src/rougail/convert/object_model.py:938 #: src/rougail/convert/object_model.py:955
msgid "\"when\" is not allowed in format version 1.0 for attribute \"{0}\"" msgid "\"when\" is not allowed in format version 1.0 for attribute \"{0}\""
msgstr "\"when\" n'est pas autorisé au format 1.0 pour l'attribut \"{0}\"" msgstr "\"when\" n'est pas autorisé au format 1.0 pour l'attribut \"{0}\""
#: src/rougail/convert/object_model.py:944 #: src/rougail/convert/object_model.py:961
#: src/rougail/convert/object_model.py:954 #: src/rougail/convert/object_model.py:971
msgid "" msgid ""
"the identifier has an invalid attribute \"{0}\", \"when\" and \"when_not\" " "the identifier has an invalid attribute \"{0}\", \"when\" and \"when_not\" "
"cannot set together" "cannot set together"
@ -531,7 +606,7 @@ msgstr ""
"l'identifiant a un attribut invalide \"{0}\", \"when\" et \"when_not\" ne " "l'identifiant a un attribut invalide \"{0}\", \"when\" et \"when_not\" ne "
"peuvent pas être défini ensemble" "peuvent pas être défini ensemble"
#: src/rougail/convert/object_model.py:980 #: src/rougail/convert/object_model.py:997
msgid "" msgid ""
"the variable \"{0}\" is not a follower, so cannot have index type for \"{1}\"" "the variable \"{0}\" is not a follower, so cannot have index type for \"{1}\""
msgstr "" msgstr ""
@ -546,20 +621,36 @@ msgstr ""
"Une variable ou une famille localisé dans l'espace de nom \"{0}\" ne devrait " "Une variable ou une famille localisé dans l'espace de nom \"{0}\" ne devrait "
"pas être utilisé dans l'espace de nom \"{1}\"" "pas être utilisé dans l'espace de nom \"{1}\""
#: src/rougail/convert/tiramisureflector.py:353 #: src/rougail/convert/tiramisureflector.py:348
msgid ""
"variable param \"{0}\" has whole attribute but it's not allowed for external "
"variable"
msgstr ""
"le paramètre de la variable \"{0}\" a un attribut whole mais ce n'est pas "
"autorisé pour une variable externe"
#: src/rougail/convert/tiramisureflector.py:351
msgid ""
"variable param \"{0}\" has dynamic attribute but it's not allowed for "
"external variable"
msgstr ""
"le paramètre de la variable \"{0}\" a un attribut dynamique mais ce n'est "
"pas autorisé pour une variable externe"
#: src/rougail/convert/tiramisureflector.py:360
msgid "internal error, {0} is not a dynamic variable" msgid "internal error, {0} is not a dynamic variable"
msgstr "erreur interne, \"{0}\" n'est pas une variable dynamique" msgstr "erreur interne, \"{0}\" n'est pas une variable dynamique"
#: src/rougail/error.py:61 src/rougail/tiramisu.py:162 #: src/rougail/error.py:61 src/rougail/tiramisu.py:235
#: src/rougail/user_datas.py:412 src/rougail/user_datas.py:415 #: src/rougail/user_data.py:452 src/rougail/user_data.py:455
msgid "{0} in {1}" msgid "{0} in {1}"
msgstr "{0} dans {1}" msgstr "{0} dans {1}"
#: src/rougail/structural_commandline/annotator.py:66 #: src/rougail/structural_commandline/annotator.py:67
msgid "alternative_name \"{0}\" conflict with \"--help\"" msgid "alternative_name \"{0}\" conflict with \"--help\""
msgstr "alternative_name \"{0}\" est en conflit avec \"--help\"" msgstr "alternative_name \"{0}\" est en conflit avec \"--help\""
#: src/rougail/structural_commandline/annotator.py:71 #: src/rougail/structural_commandline/annotator.py:72
msgid "conflict alternative_name \"{0}\": \"{1}\" and \"{2}\"" msgid "conflict alternative_name \"{0}\": \"{1}\" and \"{2}\""
msgstr "conflit dans les \"alternative_name\" \"{0}\": \"{1}\" et \"{2}\"" msgstr "conflit dans les \"alternative_name\" \"{0}\": \"{1}\" et \"{2}\""
@ -568,21 +659,33 @@ msgid "duplicate structural file name {0}"
msgstr "nom de fichier {0} de structure dupliqué" msgstr "nom de fichier {0} de structure dupliqué"
#: src/rougail/structural_directory/config.py:32 #: src/rougail/structural_directory/config.py:32
msgid "Main namespace name"
msgstr "Nom de l'espace de nom principal"
#: src/rougail/structural_directory/config.py:40
msgid "directory or string is not in \"_.step.structural\""
msgstr "directory ou string n'est pas dans \"_.step.structural\""
#: src/rougail/structural_directory/config.py:43
msgid "Directories where structural files are placed" msgid "Directories where structural files are placed"
msgstr "Répertoires où sont placés les fichiers de structure" msgstr "Répertoires où sont placés les fichiers de structure"
#: src/rougail/structural_directory/config.py:49 #: src/rougail/structural_directory/config.py:60
msgid "Sort structural from differents directories" msgid "Sort structural from differents directories"
msgstr "Trier les fichiers de structure à partir de différents répertoires" msgstr "Trier les fichiers de structure à partir de différents répertoires"
#: src/rougail/structural_directory/config.py:58
msgid "Main namespace name"
msgstr "Nom de l'espace de nom principal"
#: src/rougail/structural_directory/config.py:69 #: src/rougail/structural_directory/config.py:69
msgid "Namespaces are isolated" msgid "Namespaces are isolated"
msgstr "Les espaces de noms sont isolés" msgstr "Les espaces de noms sont isolés"
#: src/rougail/structural_directory/config.py:75
msgid ""
"directory or string is not in \"_.step.structural\" or \"_.main_namespace\" "
"is not set"
msgstr ""
"directory ou string n'est pas dans \"_.step.structural\" ou "
"\"_.main_namespace\" n'est pas défini"
#: src/rougail/structural_directory/config.py:78 #: src/rougail/structural_directory/config.py:78
msgid "Extra namespaces" msgid "Extra namespaces"
msgstr "Espaces de nom supplémentaires" msgstr "Espaces de nom supplémentaires"
@ -597,48 +700,234 @@ msgstr ""
"Répertoires où sont placés les fichiers de structure de l'espace de nom " "Répertoires où sont placés les fichiers de structure de l'espace de nom "
"supplémentaire" "supplémentaire"
#: src/rougail/structural_directory/config.py:106
msgid "directory is not in \"__.step.structural\""
msgstr "directory n'est pas dans \"__.step.structural\""
#: src/rougail/structural_string/config.py:32
msgid "Structural files contents"
msgstr "Contenu des fichiers de structure"
#: src/rougail/structural_string/config.py:33
#: src/rougail/structural_string/config.py:51
msgid "This variable is a list of string with YAML file format"
msgstr ""
"Cette variable est une liste de chaîne de caractère avec le format d'un "
"fichier YAML"
#: src/rougail/structural_string/config.py:45
msgid "string is not in \"_.step.structural\""
msgstr "string n'est pas dans \"_.step.structural\""
#: src/rougail/structural_string/config.py:50
msgid "Extra structural contents"
msgstr "Contenu de structure supplémentaire"
#: src/rougail/structural_string/config.py:58
msgid "string is not in \"__.step.structural\""
msgstr "string n'est pas dans \"__.step.structural\""
#: src/rougail/tiramisu.py:83 #: src/rougail/tiramisu.py:83
msgid "unknown boolean value \"{0}\"" msgid "unknown boolean value \"{0}\""
msgstr "valeur du booléen inconnue \"{0}\"" msgstr "valeur du booléen inconnue \"{0}\""
#: src/rougail/tiramisu.py:335 #: src/rougail/tiramisu.py:86
msgid "" msgid "IP must be in CIDR format"
"cannot calculating \"{0}\" attribute for variable \"{1}\" in {2} with " msgstr "l'IP doit être au format CIDR"
"parameters \"{3}\": {4}"
msgstr ""
"ne peut calculer l'attribut \"{0}\" pour la variable \"{1}\" dans {2} avec "
"les paramètres \"{3}\" : {4}"
#: src/rougail/user_datas.py:145 #: src/rougail/tiramisu.py:87
msgid "private IP are allowed"
msgstr "les IP privées sont autorisées"
#: src/rougail/tiramisu.py:88
msgid "reserved IP are allowed"
msgstr "les IP réservées sont autorisés"
#: src/rougail/tiramisu.py:91
msgid "network must be in CIDR format"
msgstr "le réseau doit être au format CIDR"
#: src/rougail/tiramisu.py:92
msgid "private network are allowed"
msgstr "les réseaux privés sont autorisés"
#: src/rougail/tiramisu.py:93
msgid "reserved network are allowed"
msgstr "les réseaux réservés sont autorisés"
#: src/rougail/tiramisu.py:96
msgid "can be range of port"
msgstr "peut être une plage de port"
#: src/rougail/tiramisu.py:97
msgid "can have the protocol"
msgstr "peut avoir le protocole"
#: src/rougail/tiramisu.py:98
msgid "port 0 is allowed"
msgstr "port 0 est autorisé"
#: src/rougail/tiramisu.py:99
msgid "well-known ports (1 to 1023) are allowed"
msgstr "les ports connus (1 à 1023) sont autorisés"
#: src/rougail/tiramisu.py:100
msgid "registred ports (1024 to 49151) are allowed"
msgstr "les ports enregistrés (1024 à 49151) sont autorisés"
#: src/rougail/tiramisu.py:101
msgid "private ports (greater than 49152) are allowed"
msgstr "les ports privés (supérieur à 49152) sont autorisés"
#: src/rougail/tiramisu.py:104
msgid "type of domainname"
msgstr "type de nom de domaine"
#: src/rougail/tiramisu.py:104
msgid "type {0}"
msgstr "type de {0}"
#: src/rougail/tiramisu.py:105
msgid "the domain name can starts by a dot"
msgstr "le nom de domaine peut démarré par un point"
#: src/rougail/tiramisu.py:106
msgid "the domain name can be a hostname"
msgstr "le nom de domaine peut être un nom d'hôte"
#: src/rougail/tiramisu.py:107
msgid "the domain name can be an IP"
msgstr "le nom de domaine peut être une IP"
#: src/rougail/tiramisu.py:108
msgid "the domain name can be network in CIDR format"
msgstr "le nom de domaine peut être un réseau au format CIDR"
#: src/rougail/tiramisu.py:109
msgid "the domain name must exist"
msgstr "le nom de domaine doit exister"
#: src/rougail/tiramisu.py:119 src/rougail/tiramisu.py:125
msgid "the minimum value"
msgstr "la valeur minimale"
#: src/rougail/tiramisu.py:119 src/rougail/tiramisu.py:125
msgid "the minimum value is {0}"
msgstr "la valeur minimale est {0}"
#: src/rougail/tiramisu.py:120 src/rougail/tiramisu.py:126
msgid "the maximum value"
msgstr "la valeur maximale"
#: src/rougail/tiramisu.py:120 src/rougail/tiramisu.py:126
msgid "the maximum value is {0}"
msgstr "la valeur maximale est {0}"
#: src/rougail/tiramisu.py:135
msgid "minimum characters length for the secret"
msgstr "longueur minimum de caractère pour un secret"
#: src/rougail/tiramisu.py:135
msgid "minimum length for the secret is {0} characters"
msgstr "longueur minimum pour un secret est de {0} caractères"
#: src/rougail/tiramisu.py:136
msgid "maximum characters length for the secret"
msgstr "longueur maximum de caractère pour un secret"
#: src/rougail/tiramisu.py:136
msgid "maximum length for the secret is {0} characters"
msgstr "longueur maximum pour un secret est de {0} caractères"
#: src/rougail/tiramisu.py:137
msgid "forbidden characters"
msgstr "caractères interdits"
#: src/rougail/tiramisu.py:137
msgid "forbidden characters: {0}"
msgstr "caractères interdits: {0}"
#: src/rougail/tiramisu.py:144
msgid "this filename could be a relative path"
msgstr "le nom de fichier peut être une chemin relatif"
#: src/rougail/tiramisu.py:145
msgid "this file must exist"
msgstr "le fichier doit exister"
#: src/rougail/tiramisu.py:146
msgid "file type allowed"
msgstr "type de fichier autorisé"
#: src/rougail/tiramisu.py:146
msgid "file type allowed: {0}"
msgstr "type de fichier autorisé: {0}"
#: src/rougail/tiramisu.py:436
msgid "cannot calculate the variable \"{0}\""
msgstr "ne peut calculer la variable \"{0}\""
#: src/rougail/tiramisu.py:437
msgid ""
"the attribute \"{0}\" in {1} with the parameters \"{2}\" causes the error: "
"{3}"
msgstr ""
"l'attribut \"{0}\" dans {1} avec les paramètres \"{2}\" provoque l'erreur : "
"{3}"
#: src/rougail/tiramisu.py:455
msgid "cannot converting the variable \"{0}\""
msgstr "ne peut convertir la variable \"{0}\""
#: src/rougail/tiramisu.py:456
msgid "\"{0}\" is an invalid {1}"
msgstr "\"{0}\" est un {1} invalide"
#: src/rougail/tiramisu.py:458
msgid "the attribute \"{0}\" in {1} causes the error: {2}"
msgstr "l'attribut \"{0}\" dans {1} provoque l'erreur : {2}"
#: src/rougail/user_data.py:146
msgid "" msgid ""
"cannot load variable path \"{0}\", the identifier \"{1}\" is not valid in {2}" "cannot load variable path \"{0}\", the identifier \"{1}\" is not valid in {2}"
msgstr "" msgstr ""
"ne peut charger la variable \"{0}\", l'identifiant \"{1}\" n'est pas valide " "ne peut charger la variable \"{0}\", l'identifiant \"{1}\" n'est pas valide "
"dans {2}" "dans {2}"
#: src/rougail/user_datas.py:229 #: src/rougail/user_data.py:230
msgid "the variable \"{0}\" contains secrets and should not be defined in {1}" msgid "the variable contains secrets and should not be defined in {0}"
msgstr "" msgstr ""
"la variable \"{0}\" contient des secrets et ne devrait pas être défini dans " "la variable contient des secrets et ne devrait pas être défini dans {0}"
"{1}"
#: src/rougail/user_datas.py:269 #: src/rougail/user_data.py:269
msgid "loaded from {0}" msgid "loaded from {0}"
msgstr "chargée depuis {0}" msgstr "chargée depuis {0}"
#: src/rougail/user_datas.py:311 #: src/rougail/user_data.py:311
msgid "" msgid ""
"cannot set the value \"{0}\" to the family {1}, it will be ignored when " "is a family so we cannot set the value \"{0}\", it has been loading from {1}"
"loading from {2}"
msgstr "" msgstr ""
"impossible de définir la valeur \"{0}\" à la famille {1}, elle sera ignorée " "est une famille donc il n'est pas possible de définir la valeur \"{0}\", "
"lors du chargement depuis {2}" "elle a été chargée depuis {1}"
#: src/rougail/user_datas.py:322 src/rougail/user_datas.py:339 #: src/rougail/user_data.py:315
msgid "{0} loaded from {1}" msgid ""
msgstr "{0} chargée depuis {1}" "is a family so we cannot set the value \"{0}\", it will be ignored when "
"loading from {1}"
msgstr ""
"est une famille donc il n'est pas possible de définir la valeur \"{0}\", "
"elle sera ignorée lors du chargement depuis {1}"
#: src/rougail/user_datas.py:327 #: src/rougail/user_data.py:326
msgid "{0}, it has been loaded from {1}"
msgstr "{0}, elle a été chargée depuis {1}"
#: src/rougail/user_data.py:332
msgid "variable or family \"{0}\" does not exist, it has been loading from {1}"
msgstr ""
"la variable ou la famille \"{0}\" n'existe pas, elle a été chargée depuis {1}"
#: src/rougail/user_data.py:336
msgid "" msgid ""
"variable or family \"{0}\" does not exist, it will be ignored when loading " "variable or family \"{0}\" does not exist, it will be ignored when loading "
"from {1}" "from {1}"
@ -646,7 +935,12 @@ msgstr ""
"la variable ou la famille \"{0}\" n'existe pas, elle sera ignorée lors du " "la variable ou la famille \"{0}\" n'existe pas, elle sera ignorée lors du "
"chargement depuis {1}" "chargement depuis {1}"
#: src/rougail/user_datas.py:333 #: src/rougail/user_data.py:342
msgid "\"{0}\" is the name of a dynamic family, it has been loading from {1}"
msgstr ""
"\"{0}\" est le nom d'une famille dynamique, elle a été chargée depuis {1}"
#: src/rougail/user_data.py:346
msgid "" msgid ""
"\"{0}\" is the name of a dynamic family, it will be ignored when loading " "\"{0}\" is the name of a dynamic family, it will be ignored when loading "
"from {1}" "from {1}"
@ -654,7 +948,16 @@ msgstr ""
"\"{0}\" est le nom d'une famille dynamique, il sera ignoré lors du " "\"{0}\" est le nom d'une famille dynamique, il sera ignoré lors du "
"chargement depuis {1}" "chargement depuis {1}"
#: src/rougail/user_datas.py:369 #: src/rougail/user_data.py:354
msgid "{0} loaded from {1}"
msgstr "{0} chargée depuis {1}"
#: src/rougail/user_data.py:385
msgid "variable {0} at index \"{1}\" is {2}, it has been loading from {3}"
msgstr ""
"la variable {0} à l'index \"{1}\" est {2}, elle a été chargée depuis {3}"
#: src/rougail/user_data.py:389
msgid "" msgid ""
"variable {0} at index \"{1}\" is {2}, it will be ignored when loading from " "variable {0} at index \"{1}\" is {2}, it will be ignored when loading from "
"{3}" "{3}"
@ -662,23 +965,50 @@ msgstr ""
"la variable {0} à l'index \"{1}\" est {2}, elle sera ignorée lors du " "la variable {0} à l'index \"{1}\" est {2}, elle sera ignorée lors du "
"chargement depuis {3}" "chargement depuis {3}"
#: src/rougail/user_datas.py:380 #: src/rougail/user_data.py:402
msgid "family {0} is {1}, {2} at index \"{3}\", it has been loading from {4}"
msgstr ""
"la famille {0} est {1}, {2} à l'index \"{3}\", elle a été chargée depuis {4}"
#: src/rougail/user_data.py:406
msgid "" msgid ""
"family {0} is {1}, {2} at index \"{3}\" will be ignored when loading from {4}" "family {0} is {1}, {2} at index \"{3}\", it will be ignored when loading "
"from {4}"
msgstr "" msgstr ""
"la famille {0} est {1}, {2} à l'index \"{3}\" sera ignorée lors du " "la famille {0} est {1}, {2} à l'index \"{3}\", elle a été chargée depuis {4}"
"chargement depuis {4}"
#: src/rougail/user_datas.py:393 #: src/rougail/user_data.py:421
msgid "variable {0} is {1}, it will be ignored when loading from {2}" msgid "variable is {0}, it has been loading from {1}"
msgstr "la variable est {0}, elle a été chargée depuis {1}"
#: src/rougail/user_data.py:425
msgid "variable is {0}, it will be ignored when loading from {1}"
msgstr "la variable est {0}, elle sera ignorée lors du chargement depuis {1}"
#: src/rougail/user_data.py:435
msgid ""
"family {0} is {1}, so cannot access to {2}, it has been loading from {3}"
msgstr "" msgstr ""
"la variable {0} est {1}, elle sera ignorée lors du chargement depuis {2}" "la famille {0} est {1}, donc ne peut accéder à {2}, elle a été chargée "
"depuis {3}"
#: src/rougail/user_datas.py:401 #: src/rougail/user_data.py:439
msgid "family {0} is {1}, {2} will be ignored when loading from {3}" msgid ""
msgstr "la famille {0} est {1}, {2} sera ignorée lors du chargement depuis {3}" "family {0} is {1}, so cannot access to {2}, it will be ignored when loading "
"from {3}"
msgstr ""
"la famille {0} est {1}, donc ne peut accéder à {2}, sera ignorée lors du "
"chargement depuis {3}"
#: src/rougail/user_datas.py:421 #: src/rougail/user_data.py:461
msgid ""
"the value \"{0}\" is an invalid {1} for {2} at index \"{3}\", {4}, it has "
"been loading from {5}"
msgstr ""
"la valeur \"{0}\" est un {1} invalide pour {2} à l'index \"{3}\", {4}, elle "
"a été chargée depuis {5}"
#: src/rougail/user_data.py:465
msgid "" msgid ""
"the value \"{0}\" is an invalid {1} for {2} at index \"{3}\", {4}, it will " "the value \"{0}\" is an invalid {1} for {2} at index \"{3}\", {4}, it will "
"be ignored when loading from {5}" "be ignored when loading from {5}"
@ -686,13 +1016,18 @@ msgstr ""
"la valeur \"{0}\" est un {1} invalide pour {2} à l'index \"{3}\", {4}, elle " "la valeur \"{0}\" est un {1} invalide pour {2} à l'index \"{3}\", {4}, elle "
"sera ignorée lors du chargement depuis {5}" "sera ignorée lors du chargement depuis {5}"
#: src/rougail/user_datas.py:435 #: src/rougail/user_data.py:481
msgid "" msgid "the value \"{0}\" is an invalid {1}, {2}, it has been loading from {3}"
"the value \"{0}\" is an invalid {1} for {2}, {3}, it will be ignored when "
"loading from {4}"
msgstr "" msgstr ""
"la valeur \"{0}\" est un {1} invalide pour {2}, {3}, elle sera ignorée lors " "la valeur \"{0}\" est un {1} invalide pour {2}, elle a été chargée depuis {3}"
"du chargement depuis {4}"
#: src/rougail/user_data.py:485
msgid ""
"the value \"{0}\" is an invalid {1}, {2}, it will be ignored when loading "
"from {3}"
msgstr ""
"la valeur \"{0}\" est un {1} invalide pour {2}, elle sera ignorée lors du "
"chargement depuis {4}"
#: src/rougail/utils.py:56 #: src/rougail/utils.py:56
msgid "" msgid ""
@ -702,30 +1037,41 @@ msgstr ""
"nom invalide pour la variable ou famille \"{0}\" doit seulement contenir des " "nom invalide pour la variable ou famille \"{0}\" doit seulement contenir des "
"caractères ascii minuscule, nombre or _" "caractères ascii minuscule, nombre or _"
#: src/rougail/utils.py:103 #: src/rougail/utils.py:104
msgid "error in jinja \"{0}\" for the variable \"{1}\": {2}" msgid "error for the variable \"{1}\" in jinja \"{0}\": {2}"
msgstr "erreur dans Jinja \"{0}\" pour la variable \"{1}\": {2}" msgstr "erreur pour la variable \"{1}\" dans le jinja \"{0}\": {2}"
#: src/rougail/utils.py:212 #: src/rougail/utils.py:213
msgid "mandatory" msgid "mandatory"
msgstr "obligatoire" msgstr "obligatoire"
#: src/rougail/utils.py:213 #: src/rougail/utils.py:214
msgid "hidden" msgid "hidden"
msgstr "cachée" msgstr "cachée"
#: src/rougail/utils.py:214 #: src/rougail/utils.py:215
msgid "disabled" msgid "disabled"
msgstr "désactivé" msgstr "désactivé"
#: src/rougail/utils.py:215 #: src/rougail/utils.py:216
msgid "unique" msgid "unique"
msgstr "unique" msgstr "unique"
#: src/rougail/utils.py:216 #: src/rougail/utils.py:217
msgid "auto modified" msgid "auto modified"
msgstr "auto modifiée" msgstr "auto modifiée"
#~ msgid "The secret pattern to build item name in Bitwarden"
#~ msgstr ""
#~ "Le patron de secret pour construire le nom de l'élément dans Bitwarden"
#~ msgid ""
#~ "cannot calculating \"{0}\" attribute for variable \"{1}\" in {2} with "
#~ "parameters \"{3}\": {4}"
#~ msgstr ""
#~ "ne peut calculer l'attribut \"{0}\" pour la variable \"{1}\" dans {2} "
#~ "avec les paramètres \"{3}\" : {4}"
#, fuzzy #, fuzzy
#~| msgid "" #~| msgid ""
#~| "we need {0} values when there are {{{{ var | length }}}} ({{{{ var | " #~| "we need {0} values when there are {{{{ var | length }}}} ({{{{ var | "
@ -793,9 +1139,6 @@ msgstr "auto modifiée"
#~ msgid "error in {0}: {1}" #~ msgid "error in {0}: {1}"
#~ msgstr "erreur dans {0} : {1}" #~ msgstr "erreur dans {0} : {1}"
#~ msgid "cannot find variable \"{0}\" from {1}: {2}"
#~ msgstr "ne peut trouver la variable \"{0}\" depuis {1} : {2}"
#~ msgid "the option \"{0}\" is an option description" #~ msgid "the option \"{0}\" is an option description"
#~ msgstr "l'option \"{0}\" est une option description" #~ msgstr "l'option \"{0}\" est une option description"

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-11-21 08:31+0100\n" "POT-Creation-Date: 2025-12-22 08:46+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"
@ -127,75 +127,122 @@ msgstr ""
msgid "the variable \"{0}\" has an unvalid default value \"{1}\" should be in {2}" msgid "the variable \"{0}\" has an unvalid default value \"{1}\" should be in {2}"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:276 #: src/rougail/config/__init__.py:271
msgid "Structure format version by default, if not specified in structure file" msgid "Default version of the structural file format"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:284 #: src/rougail/config/__init__.py:272
msgid "This value is only used if the version is not set in the structural file"
msgstr ""
#: src/rougail/config/__init__.py:280
msgid "File with functions" msgid "File with functions"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:296 #: src/rougail/config/__init__.py:281
msgid "This file contains filters and additional Jinja2 functions usable in structure files"
msgstr ""
#: src/rougail/config/__init__.py:293
msgid "All modes level available" msgid "All modes level available"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:308 #: src/rougail/config/__init__.py:305
msgid "Default mode for a family" msgid "Default mode for a family"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:311
msgid "the first one defined in \"modes_level\""
msgstr ""
#: src/rougail/config/__init__.py:317 src/rougail/config/__init__.py:344
msgid "when no mode is defined in \"modes_level\""
msgstr ""
#: src/rougail/config/__init__.py:324 src/rougail/config/__init__.py:351
msgid "this mode must be available in \"modes_level\""
msgstr ""
#: src/rougail/config/__init__.py:328 #: src/rougail/config/__init__.py:328
msgid "Default mode for a variable" msgid "Default mode for a variable"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:352 #: src/rougail/config/__init__.py:338
msgid "if the variable \"modes_level\" is defined, the default value is the second available element, otherwise, the first"
msgstr ""
#: src/rougail/config/__init__.py:355
msgid "Option name for the base option" msgid "Option name for the base option"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:357 #: src/rougail/config/__init__.py:360
msgid "In cache file, do not importation of Tiramisu and other dependencies" msgid "In cache file, do not importation of Tiramisu and other dependencies"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:362 #: src/rougail/config/__init__.py:365
msgid "Tiramisu cache filename" msgid "Store Tiramisu cache filename"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:370 #: src/rougail/config/__init__.py:366
msgid "Name of internal functions that we can use as a function" msgid ""
"This file contains the Tiramisu instructions used internally to load the variables.\n"
"\n"
"This file can be used for debugging"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:376 #: src/rougail/config/__init__.py:376
msgid "Name of extra annotators" msgid "Name of internal functions that we can use as a function"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:382 #: src/rougail/config/__init__.py:382
msgid "Suffix add to generated options name" msgid "Name of extra annotators"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:388 #: src/rougail/config/__init__.py:388
msgid "Suffix add to generated options name"
msgstr ""
#: src/rougail/config/__init__.py:394
msgid "Every variables in calculation are optionals" msgid "Every variables in calculation are optionals"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:392 #: src/rougail/config/__init__.py:398
msgid "Loads redefine variables even if there don't already exists" msgid "Loads redefine variables even if there don't already exists"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:399 #: src/rougail/config/__init__.py:402
msgid "The secret pattern to build item name in Bitwarden" msgid "The secret manager"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:400 #: src/rougail/config/__init__.py:405
msgid "The pattern is in Jinja format" msgid "The secret pattern to constructing the name of the item searched for in the secret manager"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:428 #: src/rougail/config/__init__.py:406
msgid "The pattern is in Jinja2 format"
msgstr ""
#: src/rougail/config/__init__.py:415
msgid "structural"
msgstr ""
#: src/rougail/config/__init__.py:416
msgid "user datas"
msgstr ""
#: src/rougail/config/__init__.py:417
msgid "output"
msgstr ""
#: src/rougail/config/__init__.py:438
msgid "Select for {0}" msgid "Select for {0}"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:508 #: src/rougail/config/__init__.py:500
msgid "Override default parameters for option type" msgid "Override default parameters for option type"
msgstr "" msgstr ""
#: src/rougail/config/__init__.py:511 #: src/rougail/config/__init__.py:503
msgid "Default parameters for option type" msgid "Default parameters for option type"
msgstr "" msgstr ""
@ -231,138 +278,142 @@ msgstr ""
msgid "invalid \"structural\" definition ({0}), we cannot load any structural file!" msgid "invalid \"structural\" definition ({0}), we cannot load any structural file!"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:121 #: src/rougail/convert/object_model.py:132
msgid "cannot find variable \"{0}\" defined in attribute \"{1}\" for \"{2}\"" msgid "cannot find variable \"{0}\" defined in attribute \"{1}\" for \"{2}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:127 #: src/rougail/convert/object_model.py:138
msgid "the variable \"{0}\" is in fact a family in attribute \"{1}\" for \"{2}\"" msgid "the variable \"{0}\" is in fact a family in attribute \"{1}\" for \"{2}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:132 #: src/rougail/convert/object_model.py:143
#: src/rougail/convert/object_model.py:513 #: src/rougail/convert/object_model.py:527
msgid "unknown object \"{0}\" in attribute \"{1}\" for \"{2}\"" msgid "unknown object \"{0}\" in attribute \"{1}\" for \"{2}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:151 #: src/rougail/convert/object_model.py:162
msgid "identifier parameter for \"{0}\" in \"{1}\" cannot be set none dynamic family" msgid "identifier parameter for \"{0}\" in \"{1}\" cannot be set none dynamic family"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:180 #: src/rougail/convert/object_model.py:191
msgid "cannot find variable \"{0}\" defined in \"{1}\" for \"{2}\"" msgid "cannot find variable \"{0}\" defined in \"{1}\" for \"{2}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:185 #: src/rougail/convert/object_model.py:196
msgid "variable \"{0}\" defined in \"{1}\" for \"{2}\" is a dynamic variable" msgid "variable \"{0}\" defined in \"{1}\" for \"{2}\" is a dynamic variable"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:202 #: src/rougail/convert/object_model.py:213
msgid "the variable \"{0}\" is not a follower, so cannot have index type for param in \"{1}\"" msgid "the variable \"{0}\" is not a follower, so cannot have index type for param in \"{1}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:252 #: src/rougail/convert/object_model.py:263
msgid "\"warnings\" are only available with attribute \"{self.attribute_name}\" for variable \"{self.ori_path}\"" msgid "\"warnings\" are only available with attribute \"{self.attribute_name}\" for variable \"{self.ori_path}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:314 #: src/rougail/convert/object_model.py:325
msgid "the variable \"{0}\" has a depreciated return_type \"{1}\", please use \"{2}\" instead in \"{3}\"" msgid "the variable \"{0}\" has a depreciated return_type \"{1}\", please use \"{2}\" instead in {3}"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:404 #: src/rougail/convert/object_model.py:415
#: src/rougail/convert/object_model.py:435 #: src/rougail/convert/object_model.py:446
msgid "variable \"{0}\" has a calculating \"{1}\" with an invalid return_type, should be boolean or string, not \"{2}\"" msgid "variable \"{0}\" has a calculating \"{1}\" with an invalid return_type, should be boolean or string, not \"{2}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:411 #: src/rougail/convert/object_model.py:422
msgid "the variable \"{0}\" has a return_type \"{1}\", for attribute \"{2}\" but has not description in {3}" msgid "the variable \"{0}\" has a return_type \"{1}\", for attribute \"{2}\" but has not description in {3}"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:416 #: src/rougail/convert/object_model.py:427
msgid "value is invalid" msgid "value is invalid"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:508 #: src/rougail/convert/object_model.py:522
msgid "a variable \"{0}\" is needs in attribute \"{1}\" for \"{2}\" but it's a family" msgid "a variable \"{0}\" is needs in attribute \"{1}\" for \"{2}\" but it's a family"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:533 #: src/rougail/convert/object_model.py:547
msgid "variable \"{0}\" has an attribute \"{1}\" calculated with the unknown variable \"{2}\"" msgid "variable \"{0}\" has an attribute \"{1}\" calculated with the unknown variable \"{2}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:585 #: src/rougail/convert/object_model.py:599
msgid "the variable \"{0}\" has an invalid \"{1}\" the variable \"{2}\" is in a sub dynamic option" msgid "the variable \"{0}\" has an invalid \"{1}\" the variable \"{2}\" is in a sub dynamic option"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:594 #: src/rougail/convert/object_model.py:608
msgid "the leader \"{0}\" has an invalid \"{1}\" the follower \"{2}\" is a multi" msgid "the leader \"{0}\" has an invalid \"{1}\" the follower \"{2}\" is a multi"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:636 #: src/rougail/convert/object_model.py:650
msgid "the variable \"{0}\" has an invalid attribute \"{1}\", the variable \"{2}\" must not be multi" msgid "the variable \"{0}\" has an invalid attribute \"{1}\", the variable \"{2}\" must not be multi"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:650 #: src/rougail/convert/object_model.py:664
msgid "the variable \"{0}\" has an invalid attribute \"{1}\", the variable must not be a multi or the variable \"{2}\" must be multi" msgid "the variable \"{0}\" has an invalid attribute \"{1}\", the variable must not be a multi or the variable \"{2}\" must be multi"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:664 #: src/rougail/convert/object_model.py:678
msgid "the variable \"{0}\" has an invalid attribute \"{1}\", the variable must be a multi or the variable \"{2}\" must not be multi" msgid "the variable \"{0}\" has an invalid attribute \"{1}\", the variable must be a multi or the variable \"{2}\" must not be multi"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:678 #: src/rougail/convert/object_model.py:692
msgid "the variable \"{0}\" has an invalid attribute \"{1}\", the variable \"{2}\" is multi but is inside a list" msgid "the variable \"{0}\" has an invalid attribute \"{1}\", the variable \"{2}\" is multi but is inside a list"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:700 #: src/rougail/convert/object_model.py:714
msgid "the variable \"{0}\" is waiting for a list as \"{1}\" but the attribute \"default\" is not a list (\"{2}\")" msgid "the variable \"{0}\" is waiting for a list as \"{1}\" but the attribute \"default\" is not a list (\"{2}\")"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:704 #: src/rougail/convert/object_model.py:718
msgid "the variable \"{0}\" is not waiting for a list as \"{1}\" but the attribute \"default\" is a list (\"{2}\")" msgid "the variable \"{0}\" is not waiting for a list as \"{1}\" but the attribute \"default\" is a list (\"{2}\")"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:726 #: src/rougail/convert/object_model.py:740
msgid "\"{0}\" attribut shall not have an \"optional\" attribute without the \"default\" attribute for variable \"{1}\"" msgid "\"{0}\" attribut shall not have an \"optional\" attribute without the \"default\" attribute for variable \"{1}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:748 #: src/rougail/convert/object_model.py:762
msgid "variable \"{0}\" has a default value calculated with \"{1}\" which has incompatible type" msgid "variable \"{0}\" has a default value calculated with \"{1}\" which has incompatible type"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:790 #: src/rougail/convert/object_model.py:804
msgid "the variable \"{0}\" is waiting for a boolean as \"{1}\" but the attribute \"default\" is not a boolean (\"{2}\")" msgid "the variable \"{0}\" is waiting for a boolean as \"{1}\" but the attribute \"default\" is not a boolean (\"{2}\")"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:812 #: src/rougail/convert/object_model.py:826
msgid "\"when\" is not allowed in format version 1.0 for attribute \"{0}\" for variable \"{1}\"" msgid "\"when\" is not allowed in format version 1.0 for attribute \"{0}\" for variable \"{1}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:817 #: src/rougail/convert/object_model.py:831
msgid "the variable \"{0}\" has an invalid attribute \"{1}\", \"when\" and \"when_not\" cannot set together" msgid "the variable \"{0}\" has an invalid attribute \"{1}\", \"when\" and \"when_not\" cannot set together"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:825 #: src/rougail/convert/object_model.py:839
msgid "\"when_not\" is not allowed in format version 1.0 for attribute \"{0}\" for variable \"{1}\"" msgid "\"when_not\" is not allowed in format version 1.0 for attribute \"{0}\" for variable \"{1}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:881 #: src/rougail/convert/object_model.py:850
msgid "\"when\" or \"when_not\" is mandatory for the not boolean variable \"{0}\" in attribute \"{1}\""
msgstr ""
#: src/rougail/convert/object_model.py:898
msgid "cannot find variable \"{0}\" for the information \"{1}\" when calculating \"{2}\"" msgid "cannot find variable \"{0}\" for the information \"{1}\" when calculating \"{2}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:886 #: src/rougail/convert/object_model.py:903
msgid "identifier not allowed for the information \"{0}\" when calculating \"{1}\"" msgid "identifier not allowed for the information \"{0}\" when calculating \"{1}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:938 #: src/rougail/convert/object_model.py:955
msgid "\"when\" is not allowed in format version 1.0 for attribute \"{0}\"" msgid "\"when\" is not allowed in format version 1.0 for attribute \"{0}\""
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:944 #: src/rougail/convert/object_model.py:961
#: src/rougail/convert/object_model.py:954 #: src/rougail/convert/object_model.py:971
msgid "the identifier has an invalid attribute \"{0}\", \"when\" and \"when_not\" cannot set together" msgid "the identifier has an invalid attribute \"{0}\", \"when\" and \"when_not\" cannot set together"
msgstr "" msgstr ""
#: src/rougail/convert/object_model.py:980 #: src/rougail/convert/object_model.py:997
msgid "the variable \"{0}\" is not a follower, so cannot have index type for \"{1}\"" msgid "the variable \"{0}\" is not a follower, so cannot have index type for \"{1}\""
msgstr "" msgstr ""
@ -370,20 +421,28 @@ msgstr ""
msgid "A variable or a family located in the \"{0}\" namespace shall not be used in the \"{1}\" namespace" msgid "A variable or a family located in the \"{0}\" namespace shall not be used in the \"{1}\" namespace"
msgstr "" msgstr ""
#: src/rougail/convert/tiramisureflector.py:353 #: src/rougail/convert/tiramisureflector.py:348
msgid "variable param \"{0}\" has whole attribute but it's not allowed for external variable"
msgstr ""
#: src/rougail/convert/tiramisureflector.py:351
msgid "variable param \"{0}\" has dynamic attribute but it's not allowed for external variable"
msgstr ""
#: src/rougail/convert/tiramisureflector.py:360
msgid "internal error, {0} is not a dynamic variable" msgid "internal error, {0} is not a dynamic variable"
msgstr "" msgstr ""
#: src/rougail/error.py:61 src/rougail/tiramisu.py:162 #: src/rougail/error.py:61 src/rougail/tiramisu.py:235
#: src/rougail/user_datas.py:412 src/rougail/user_datas.py:415 #: src/rougail/user_data.py:452 src/rougail/user_data.py:455
msgid "{0} in {1}" msgid "{0} in {1}"
msgstr "" msgstr ""
#: src/rougail/structural_commandline/annotator.py:66 #: src/rougail/structural_commandline/annotator.py:67
msgid "alternative_name \"{0}\" conflict with \"--help\"" msgid "alternative_name \"{0}\" conflict with \"--help\""
msgstr "" msgstr ""
#: src/rougail/structural_commandline/annotator.py:71 #: src/rougail/structural_commandline/annotator.py:72
msgid "conflict alternative_name \"{0}\": \"{1}\" and \"{2}\"" msgid "conflict alternative_name \"{0}\": \"{1}\" and \"{2}\""
msgstr "" msgstr ""
@ -392,21 +451,29 @@ msgid "duplicate structural file name {0}"
msgstr "" msgstr ""
#: src/rougail/structural_directory/config.py:32 #: src/rougail/structural_directory/config.py:32
msgid "Main namespace name"
msgstr ""
#: src/rougail/structural_directory/config.py:40
msgid "directory or string is not in \"_.step.structural\""
msgstr ""
#: src/rougail/structural_directory/config.py:43
msgid "Directories where structural files are placed" msgid "Directories where structural files are placed"
msgstr "" msgstr ""
#: src/rougail/structural_directory/config.py:49 #: src/rougail/structural_directory/config.py:60
msgid "Sort structural from differents directories" msgid "Sort structural from differents directories"
msgstr "" msgstr ""
#: src/rougail/structural_directory/config.py:58
msgid "Main namespace name"
msgstr ""
#: src/rougail/structural_directory/config.py:69 #: src/rougail/structural_directory/config.py:69
msgid "Namespaces are isolated" msgid "Namespaces are isolated"
msgstr "" msgstr ""
#: src/rougail/structural_directory/config.py:75
msgid "directory or string is not in \"_.step.structural\" or \"_.main_namespace\" is not set"
msgstr ""
#: src/rougail/structural_directory/config.py:78 #: src/rougail/structural_directory/config.py:78
msgid "Extra namespaces" msgid "Extra namespaces"
msgstr "" msgstr ""
@ -419,91 +486,304 @@ msgstr ""
msgid "Directories where extra structural files are placed" msgid "Directories where extra structural files are placed"
msgstr "" msgstr ""
#: src/rougail/structural_directory/config.py:106
msgid "directory is not in \"__.step.structural\""
msgstr ""
#: src/rougail/structural_string/config.py:32
msgid "Structural files contents"
msgstr ""
#: src/rougail/structural_string/config.py:33
#: src/rougail/structural_string/config.py:51
msgid "This variable is a list of string with YAML file format"
msgstr ""
#: src/rougail/structural_string/config.py:45
msgid "string is not in \"_.step.structural\""
msgstr ""
#: src/rougail/structural_string/config.py:50
msgid "Extra structural contents"
msgstr ""
#: src/rougail/structural_string/config.py:58
msgid "string is not in \"__.step.structural\""
msgstr ""
#: src/rougail/tiramisu.py:83 #: src/rougail/tiramisu.py:83
msgid "unknown boolean value \"{0}\"" msgid "unknown boolean value \"{0}\""
msgstr "" msgstr ""
#: src/rougail/tiramisu.py:335 #: src/rougail/tiramisu.py:86
msgid "cannot calculating \"{0}\" attribute for variable \"{1}\" in {2} with parameters \"{3}\": {4}" msgid "IP must be in CIDR format"
msgstr "" msgstr ""
#: src/rougail/user_datas.py:145 #: src/rougail/tiramisu.py:87
msgid "private IP are allowed"
msgstr ""
#: src/rougail/tiramisu.py:88
msgid "reserved IP are allowed"
msgstr ""
#: src/rougail/tiramisu.py:91
msgid "network must be in CIDR format"
msgstr ""
#: src/rougail/tiramisu.py:92
msgid "private network are allowed"
msgstr ""
#: src/rougail/tiramisu.py:93
msgid "reserved network are allowed"
msgstr ""
#: src/rougail/tiramisu.py:96
msgid "can be range of port"
msgstr ""
#: src/rougail/tiramisu.py:97
msgid "can have the protocol"
msgstr ""
#: src/rougail/tiramisu.py:98
msgid "port 0 is allowed"
msgstr ""
#: src/rougail/tiramisu.py:99
msgid "well-known ports (1 to 1023) are allowed"
msgstr ""
#: src/rougail/tiramisu.py:100
msgid "registred ports (1024 to 49151) are allowed"
msgstr ""
#: src/rougail/tiramisu.py:101
msgid "private ports (greater than 49152) are allowed"
msgstr ""
#: src/rougail/tiramisu.py:104
msgid "type of domainname"
msgstr ""
#: src/rougail/tiramisu.py:104
msgid "type {0}"
msgstr ""
#: src/rougail/tiramisu.py:105
msgid "the domain name can starts by a dot"
msgstr ""
#: src/rougail/tiramisu.py:106
msgid "the domain name can be a hostname"
msgstr ""
#: src/rougail/tiramisu.py:107
msgid "the domain name can be an IP"
msgstr ""
#: src/rougail/tiramisu.py:108
msgid "the domain name can be network in CIDR format"
msgstr ""
#: src/rougail/tiramisu.py:109
msgid "the domain name must exist"
msgstr ""
#: src/rougail/tiramisu.py:119 src/rougail/tiramisu.py:125
msgid "the minimum value"
msgstr ""
#: src/rougail/tiramisu.py:119 src/rougail/tiramisu.py:125
msgid "the minimum value is {0}"
msgstr ""
#: src/rougail/tiramisu.py:120 src/rougail/tiramisu.py:126
msgid "the maximum value"
msgstr ""
#: src/rougail/tiramisu.py:120 src/rougail/tiramisu.py:126
msgid "the maximum value is {0}"
msgstr ""
#: src/rougail/tiramisu.py:135
msgid "minimum characters length for the secret"
msgstr ""
#: src/rougail/tiramisu.py:135
msgid "minimum length for the secret is {0} characters"
msgstr ""
#: src/rougail/tiramisu.py:136
msgid "maximum characters length for the secret"
msgstr ""
#: src/rougail/tiramisu.py:136
msgid "maximum length for the secret is {0} characters"
msgstr ""
#: src/rougail/tiramisu.py:137
msgid "forbidden characters"
msgstr ""
#: src/rougail/tiramisu.py:137
msgid "forbidden characters: {0}"
msgstr ""
#: src/rougail/tiramisu.py:144
msgid "this filename could be a relative path"
msgstr ""
#: src/rougail/tiramisu.py:145
msgid "this file must exist"
msgstr ""
#: src/rougail/tiramisu.py:146
msgid "file type allowed"
msgstr ""
#: src/rougail/tiramisu.py:146
msgid "file type allowed: {0}"
msgstr ""
#: src/rougail/tiramisu.py:436
msgid "cannot calculate the variable \"{0}\""
msgstr ""
#: src/rougail/tiramisu.py:437
msgid "the attribute \"{0}\" in {1} with the parameters \"{2}\" causes the error: {3}"
msgstr ""
#: src/rougail/tiramisu.py:455
msgid "cannot converting the variable \"{0}\""
msgstr ""
#: src/rougail/tiramisu.py:456
msgid "\"{0}\" is an invalid {1}"
msgstr ""
#: src/rougail/tiramisu.py:458
msgid "the attribute \"{0}\" in {1} causes the error: {2}"
msgstr ""
#: src/rougail/user_data.py:146
msgid "cannot load variable path \"{0}\", the identifier \"{1}\" is not valid in {2}" msgid "cannot load variable path \"{0}\", the identifier \"{1}\" is not valid in {2}"
msgstr "" msgstr ""
#: src/rougail/user_datas.py:229 #: src/rougail/user_data.py:230
msgid "the variable \"{0}\" contains secrets and should not be defined in {1}" msgid "the variable contains secrets and should not be defined in {0}"
msgstr "" msgstr ""
#: src/rougail/user_datas.py:269 #: src/rougail/user_data.py:269
msgid "loaded from {0}" msgid "loaded from {0}"
msgstr "" msgstr ""
#: src/rougail/user_datas.py:311 #: src/rougail/user_data.py:311
msgid "cannot set the value \"{0}\" to the family {1}, it will be ignored when loading from {2}" msgid "is a family so we cannot set the value \"{0}\", it has been loading from {1}"
msgstr "" msgstr ""
#: src/rougail/user_datas.py:322 src/rougail/user_datas.py:339 #: src/rougail/user_data.py:315
msgid "{0} loaded from {1}" msgid "is a family so we cannot set the value \"{0}\", it will be ignored when loading from {1}"
msgstr "" msgstr ""
#: src/rougail/user_datas.py:327 #: src/rougail/user_data.py:326
msgid "{0}, it has been loaded from {1}"
msgstr ""
#: src/rougail/user_data.py:332
msgid "variable or family \"{0}\" does not exist, it has been loading from {1}"
msgstr ""
#: src/rougail/user_data.py:336
msgid "variable or family \"{0}\" does not exist, it will be ignored when loading from {1}" msgid "variable or family \"{0}\" does not exist, it will be ignored when loading from {1}"
msgstr "" msgstr ""
#: src/rougail/user_datas.py:333 #: src/rougail/user_data.py:342
msgid "\"{0}\" is the name of a dynamic family, it has been loading from {1}"
msgstr ""
#: src/rougail/user_data.py:346
msgid "\"{0}\" is the name of a dynamic family, it will be ignored when loading from {1}" msgid "\"{0}\" is the name of a dynamic family, it will be ignored when loading from {1}"
msgstr "" msgstr ""
#: src/rougail/user_datas.py:369 #: src/rougail/user_data.py:354
msgid "{0} loaded from {1}"
msgstr ""
#: src/rougail/user_data.py:385
msgid "variable {0} at index \"{1}\" is {2}, it has been loading from {3}"
msgstr ""
#: src/rougail/user_data.py:389
msgid "variable {0} at index \"{1}\" is {2}, it will be ignored when loading from {3}" msgid "variable {0} at index \"{1}\" is {2}, it will be ignored when loading from {3}"
msgstr "" msgstr ""
#: src/rougail/user_datas.py:380 #: src/rougail/user_data.py:402
msgid "family {0} is {1}, {2} at index \"{3}\" will be ignored when loading from {4}" msgid "family {0} is {1}, {2} at index \"{3}\", it has been loading from {4}"
msgstr "" msgstr ""
#: src/rougail/user_datas.py:393 #: src/rougail/user_data.py:406
msgid "variable {0} is {1}, it will be ignored when loading from {2}" msgid "family {0} is {1}, {2} at index \"{3}\", it will be ignored when loading from {4}"
msgstr "" msgstr ""
#: src/rougail/user_datas.py:401 #: src/rougail/user_data.py:421
msgid "family {0} is {1}, {2} will be ignored when loading from {3}" msgid "variable is {0}, it has been loading from {1}"
msgstr "" msgstr ""
#: src/rougail/user_datas.py:421 #: src/rougail/user_data.py:425
msgid "variable is {0}, it will be ignored when loading from {1}"
msgstr ""
#: src/rougail/user_data.py:435
msgid "family {0} is {1}, so cannot access to {2}, it has been loading from {3}"
msgstr ""
#: src/rougail/user_data.py:439
msgid "family {0} is {1}, so cannot access to {2}, it will be ignored when loading from {3}"
msgstr ""
#: src/rougail/user_data.py:461
msgid "the value \"{0}\" is an invalid {1} for {2} at index \"{3}\", {4}, it has been loading from {5}"
msgstr ""
#: src/rougail/user_data.py:465
msgid "the value \"{0}\" is an invalid {1} for {2} at index \"{3}\", {4}, it will be ignored when loading from {5}" msgid "the value \"{0}\" is an invalid {1} for {2} at index \"{3}\", {4}, it will be ignored when loading from {5}"
msgstr "" msgstr ""
#: src/rougail/user_datas.py:435 #: src/rougail/user_data.py:481
msgid "the value \"{0}\" is an invalid {1} for {2}, {3}, it will be ignored when loading from {4}" msgid "the value \"{0}\" is an invalid {1}, {2}, it has been loading from {3}"
msgstr ""
#: src/rougail/user_data.py:485
msgid "the value \"{0}\" is an invalid {1}, {2}, it will be ignored when loading from {3}"
msgstr "" msgstr ""
#: src/rougail/utils.py:56 #: src/rougail/utils.py:56
msgid "invalid variable or family name \"{0}\" must only contains lowercase ascii character, number or _" msgid "invalid variable or family name \"{0}\" must only contains lowercase ascii character, number or _"
msgstr "" msgstr ""
#: src/rougail/utils.py:103 #: src/rougail/utils.py:104
msgid "error in jinja \"{0}\" for the variable \"{1}\": {2}" msgid "error for the variable \"{1}\" in jinja \"{0}\": {2}"
msgstr ""
#: src/rougail/utils.py:212
msgid "mandatory"
msgstr "" msgstr ""
#: src/rougail/utils.py:213 #: src/rougail/utils.py:213
msgid "hidden" msgid "mandatory"
msgstr "" msgstr ""
#: src/rougail/utils.py:214 #: src/rougail/utils.py:214
msgid "disabled" msgid "hidden"
msgstr "" msgstr ""
#: src/rougail/utils.py:215 #: src/rougail/utils.py:215
msgid "unique" msgid "disabled"
msgstr "" msgstr ""
#: src/rougail/utils.py:216 #: src/rougail/utils.py:216
msgid "unique"
msgstr ""
#: src/rougail/utils.py:217
msgid "auto modified" msgid "auto modified"
msgstr "" msgstr ""

View file

@ -76,31 +76,33 @@ class _RougailConfig:
self.add_extra_options = add_extra_options self.add_extra_options = add_extra_options
self.root = None self.root = None
def copy(self): def copy(self, backward_compatibility=None):
rougailconfig = _RougailConfig( if not self.root:
self.backward_compatibility, self.generate_config()
self.add_extra_options, config = self.config.config.copy()
config.value.importation(self.config.value.exportation())
config.property.importation(
self.config.property.exportation()
) )
if self.root: config.property.read_only()
rougailconfig.generate_config() if backward_compatibility is None:
rougailconfig.config.value.importation(self.config.value.exportation()) backward_compatibility = self.backward_compatibility
rougailconfig.config.property.importation( rougailconfig = _RougailConfig(backward_compatibility, self.add_extra_options)
self.config.property.exportation() rougailconfig.root = self.root
) rougailconfig.config = config
rougailconfig.config.property.read_only() rougailconfig.extra_vars = self.extra_vars.copy()
rougailconfig.extra_vars = self.extra_vars.copy() rougailconfig.not_in_tiramisu = NOT_IN_TIRAMISU | rougailconfig.extra_vars
for variable in self.not_in_tiramisu: for variable in self.not_in_tiramisu:
value = getattr(self, variable) value = getattr(self, variable)
if not isinstance(value, str): if not isinstance(value, str):
value = value.copy() value = value.copy()
setattr(rougailconfig, variable, value) setattr(rougailconfig, variable, value)
return rougailconfig return rougailconfig
def generate_config(self): def generate_config(self):
root, extra_vars = _rougail_config( self.root, extra_vars = _rougail_config(
self.backward_compatibility, self.add_extra_options self.backward_compatibility, self.add_extra_options
) )
self.root = root
self.config = Config( self.config = Config(
self.root, self.root,
) )
@ -123,8 +125,6 @@ class _RougailConfig:
setattr(self, key, value) setattr(self, key, value)
else: else:
self.config.property.read_write() self.config.property.read_write()
if key == "export_with_import":
key = "not_export_with_import"
key = RENAMED.get(key, key) key = RENAMED.get(key, key)
option = self.config.option(key) option = self.config.option(key)
if option.isoptiondescription() and option.isleadership(): if option.isoptiondescription() and option.isleadership():
@ -139,8 +139,6 @@ class _RougailConfig:
follower = option.followers()[0] follower = option.followers()[0]
for idx, val in enumerate(followers): for idx, val in enumerate(followers):
self.config.option(follower.path(), idx).value.set(val) self.config.option(follower.path(), idx).value.set(val)
elif key == "not_export_with_import":
option.value.set(not value)
else: else:
option.value.set(value) option.value.set(value)
self.config.property.read_only() self.config.property.read_only()
@ -153,14 +151,10 @@ class _RougailConfig:
self.generate_config() self.generate_config()
if key in self.not_in_tiramisu: if key in self.not_in_tiramisu:
return getattr(self, key) return getattr(self, key)
if key == "export_with_import":
key = "not_export_with_import"
option = self.config.option(key) option = self.config.option(key)
if option.isoptiondescription() and option.isleadership(): if option.isoptiondescription() and option.isleadership():
return self.get_leadership(option) return self.get_leadership(option)
ret = self.config.option(key).value.get() ret = self.config.option(key).value.get()
if key == "not_export_with_import":
return not ret
return ret return ret
def __contains__( def __contains__(
@ -261,19 +255,21 @@ class FakeRougailConvert(RougailConvert):
self.internal_functions = [] self.internal_functions = []
self.force_optional = False self.force_optional = False
self.structurals = ["commandline"] self.structurals = ["commandline"]
self.user_datas = [] self.user_data = []
self.output = None self.output = None
self.add_extra_options = self.add_extra_options self.add_extra_options = self.add_extra_options
self.tiramisu_cache = False self.tiramisu_cache = False
# self.tiramisu_cache = "a.py"
self.load_unexist_redefine = False self.load_unexist_redefine = False
def _rougail_config( def get_common_rougail_config(
backward_compatibility: bool = True, *,
add_extra_options: bool = True, backward_compatibility=True,
) -> "OptionDescription": ) -> str:
rougail_options = f"""default_structural_format_version: rougail_options = f"""default_structural_format_version:
description: {_('Structure format version by default, if not specified in structure file')} description: {_('Default version of the structural file format')}
help: {_('This value is only used if the version is not set in the structural file')}
alternative_name: v alternative_name: v
choices: choices:
- '1.0' - '1.0'
@ -282,6 +278,7 @@ def _rougail_config(
functions_files: functions_files:
description: {_("File with functions")} description: {_("File with functions")}
help: {_("This file contains filters and additional Jinja2 functions usable in structure files")}
alternative_name: c alternative_name: c
type: unix_filename type: unix_filename
params: params:
@ -311,17 +308,20 @@ default_family_mode:
{{% if modes_level %}} {{% if modes_level %}}
{{{{ modes_level[0] }}}} {{{{ modes_level[0] }}}}
{{% endif %}} {{% endif %}}
description: {_('the first one defined in "modes_level"')}
disabled: disabled:
jinja: | jinja: |
{{% if not modes_level %}} {{% if not modes_level %}}
No mode No mode
{{% endif %}} {{% endif %}}
description: {_('when no mode is defined in "modes_level"')}
validators: validators:
- type: jinja - type: jinja
jinja: | jinja: |
{{% if default_family_mode not in modes_level %}} {{% if default_family_mode not in modes_level %}}
not in modes_level ({{modes_level}}) not in modes_level ({{modes_level}})
{{% endif %}} {{% endif %}}
description: {_('this mode must be available in "modes_level"')}
commandline: false commandline: false
default_variable_mode: default_variable_mode:
@ -335,17 +335,20 @@ default_variable_mode:
{{{{ modes_level[1] }}}} {{{{ modes_level[1] }}}}
{{% endif %}} {{% endif %}}
{{% endif %}} {{% endif %}}
description: {_('if the variable "modes_level" is defined, the default value is the second available element, otherwise, the first')}
disabled: disabled:
jinja: | jinja: |
{{% if not modes_level %}} {{% if not modes_level %}}
No mode No mode
{{% endif %}} {{% endif %}}
description: {_('when no mode is defined in "modes_level"')}
validators: validators:
- type: jinja - type: jinja
jinja: | jinja: |
{{% if default_variable_mode not in modes_level %}} {{% if default_variable_mode not in modes_level %}}
not in modes_level ({{modes_level}}) not in modes_level ({{modes_level}})
{{% endif %}} {{% endif %}}
description: {_('this mode must be available in "modes_level"')}
commandline: false commandline: false
base_option_name: base_option_name:
@ -353,18 +356,21 @@ base_option_name:
default: baseoption default: baseoption
commandline: false commandline: false
not_export_with_import: export_with_import:
description: {_("In cache file, do not importation of Tiramisu and other dependencies")} description: {_("In cache file, do not importation of Tiramisu and other dependencies")}
default: false default: true
commandline: false commandline: false
tiramisu_cache: tiramisu_cache:
description: {_("Tiramisu cache filename")} description: {_("Store Tiramisu cache filename")}
help: "{_("This file contains the Tiramisu instructions used internally to load the variables.\n\nThis file can be used for debugging")}"
alternative_name: t alternative_name: t
type: unix_filename type: unix_filename
mandatory: false mandatory: false
params: params:
allow_relative: true allow_relative: true
types:
- file
internal_functions: internal_functions:
description: {_("Name of internal functions that we can use as a function")} description: {_("Name of internal functions that we can use as a function")}
@ -393,11 +399,11 @@ load_unexist_redefine:
commandline: false commandline: false
default: False default: False
secret_manager: secret_manager: # {_("The secret manager")}
pattern: pattern:
description: {_("The secret pattern to build item name in Bitwarden")} description: {_("The secret pattern to constructing the name of the item searched for in the secret manager")}
help: {_("The pattern is in Jinja format")} help: {_("The pattern is in Jinja2 format")}
default: "{{{{ project }}}} - {{{{ environment }}}} - {{{{ service }}}} - {{{{ user }}}}" default: "{{{{ project }}}} - {{{{ environment }}}} - {{{{ service }}}} - {{{{ user }}}}"
""" """
@ -406,6 +412,10 @@ secret_manager:
"user data": [], "user data": [],
"output": [], "output": [],
} }
processes_tr = {"structural": _("structural"),
"user data": _("user datas"),
"output": _("output"),
}
processes_empty = [] processes_empty = []
for module in get_sub_modules().values(): for module in get_sub_modules().values():
data = module.get_rougail_config(backward_compatibility=backward_compatibility) data = module.get_rougail_config(backward_compatibility=backward_compatibility)
@ -421,20 +431,18 @@ secret_manager:
if processes[process]: if processes[process]:
objects = processes[process] objects = processes[process]
process_name = normalize_family(process) process_name = normalize_family(process)
tr_process_name = _(process_name) tr_process_name = processes_tr[process]
rougail_process += f""" rougail_process += f"""
{process_name}: {process_name}:
description: {_('Select for {0}').format(tr_process_name)} description: {_('Select for {0}').format(tr_process_name)}
""" """
if process != "structural": if process != "structural":
rougail_process += """ rougail_process += """ alternative_name: {NAME[0]}
alternative_name: {NAME[0]}
""".format( """.format(
NAME=normalize_family(process), NAME=normalize_family(process),
) )
rougail_process += """ rougail_process += """ choices:
choices:
""" """
for obj in objects: for obj in objects:
rougail_process += f" - {obj['name']}\n" rougail_process += f" - {obj['name']}\n"
@ -444,24 +452,6 @@ secret_manager:
default: default:
- directory - directory
""" """
hidden_outputs = [
process["name"]
for process in processes["output"]
if process.get("allow_user_data", True)
]
if hidden_outputs:
rougail_process += """
hidden:
type: jinja
jinja: |
"""
for hidden_output in hidden_outputs:
rougail_process += """ {% if _.output is not propertyerror and _.output == 'NAME' %}
Cannot load structural for NAME output
{% endif %}
""".replace(
"NAME", hidden_output
)
elif process == "user data": elif process == "user data":
rougail_process += """ multi: true rougail_process += """ multi: true
mandatory: false""" mandatory: false"""
@ -479,7 +469,8 @@ secret_manager:
for hidden_output in hidden_outputs: for hidden_output in hidden_outputs:
rougail_process += """ {% if _.output is not propertyerror and _.output == 'NAME' %} rougail_process += """ {% if _.output is not propertyerror and _.output == 'NAME' %}
Cannot load user data for NAME output Cannot load user data for NAME output
{% endif %}""".replace( {% endif %}
description: _('cannot load user data for NAME output')""".replace(
"NAME", hidden_output "NAME", hidden_output
) )
elif objects: elif objects:
@ -505,6 +496,7 @@ secret_manager:
PROP=prop, PROP=prop,
) )
rougail_process += f""" rougail_process += f"""
define_default_params: false # {_('Override default parameters for option type')} define_default_params: false # {_('Override default parameters for option type')}
default_params: default_params:
@ -514,20 +506,35 @@ default_params:
when: false when: false
""" """
for typ, params in get_convert_option_types(): for typ, typ_description, params in get_convert_option_types():
rougail_process += f""" rougail_process += f"""
{typ}: {typ}: # {typ_description}
""" """
for key, key_type, multi, value in params: for key, key_type, description, multi, value, choices in params:
rougail_process += f""" rougail_process += f"""
{key}: {key}:
type: {key_type} """
if description:
rougail_process += f""" description: "{description}"
"""
rougail_process += f""" type: {key_type}
multi: {multi} multi: {multi}
mandatory: false mandatory: false
default: {value} default: {value}
""" """
# print(rougail_process) if choices:
rougail_process += " choices:\n"
for choice in choices:
rougail_process += f" - {choice}\n"
rougail_options += rougail_process rougail_options += rougail_process
return processes, processes_empty, rougail_options
def _rougail_config(
backward_compatibility: bool = True,
add_extra_options: bool = True,
) -> "OptionDescription":
processes, processes_empty, rougail_options = get_common_rougail_config(backward_compatibility=backward_compatibility)
convert = FakeRougailConvert(add_extra_options) convert = FakeRougailConvert(add_extra_options)
convert.init() convert.init()
convert.namespace = None convert.namespace = None

View file

@ -43,6 +43,7 @@ BASETYPE = Union[StrictBool, StrictInt, StrictFloat, StrictStr, None]
def get_convert_option_types(): def get_convert_option_types():
for typ, datas in CONVERT_OPTION.items(): for typ, datas in CONVERT_OPTION.items():
typ_description = datas.get("msg", typ)
obj = getattr(tiramisu, datas["opttype"]) obj = getattr(tiramisu, datas["opttype"])
initkwargs = datas.get("initkwargs", {}) initkwargs = datas.get("initkwargs", {})
if obj == tiramisu.SymLinkOption: if obj == tiramisu.SymLinkOption:
@ -58,16 +59,25 @@ def get_convert_option_types():
for key, value in extra.items(): for key, value in extra.items():
if key.startswith("_"): if key.startswith("_"):
continue continue
multi = False if "params" in datas and key in datas["params"]:
if isinstance(value, bool): multi = datas["params"][key].get('multi', False)
description = datas["params"][key]["description"]
choices = datas["params"][key].get("choices")
else:
description = None
choices = None
multi = False
if choices:
key_type = "choice"
elif isinstance(value, bool):
key_type = "boolean" key_type = "boolean"
elif isinstance(value, str): elif isinstance(value, str):
key_type = "string" key_type = "string"
elif isinstance(value, list): elif isinstance(value, list):
key_type = "string" key_type = "string"
multi = True multi = True
params.append((key, key_type, multi, value)) params.append((key, key_type, description, multi, value, choices))
yield typ, params yield typ, typ_description, params
class Param(BaseModel): class Param(BaseModel):
@ -101,6 +111,7 @@ class VariableParam(Param):
variable: str variable: str
propertyerror: bool = True propertyerror: bool = True
whole: bool = False whole: bool = False
dynamic: bool = True
optional: bool = False optional: bool = False
def to_param( def to_param(
@ -311,7 +322,7 @@ class JinjaCalculation(Calculation):
idx += 1 idx += 1
objectspace.jinja[jinja_path] = self.jinja objectspace.jinja[jinja_path] = self.jinja
if return_type in RENAME_TYPE: if return_type in RENAME_TYPE:
warning = _('the variable "{0}" has a depreciated return_type "{1}", please use "{2}" instead in "{3}"') warning = _('the variable "{0}" has a depreciated return_type "{1}", please use "{2}" instead in {3}')
warn( warn(
warning.format(self.path, return_type, RENAME_TYPE[return_type], display_xmlfiles(self.xmlfiles)), warning.format(self.path, return_type, RENAME_TYPE[return_type], display_xmlfiles(self.xmlfiles)),
DeprecationWarning, DeprecationWarning,
@ -460,9 +471,12 @@ class JinjaCalculation(Calculation):
objectspace, objectspace,
) )
elif self.attribute_name == "dynamic": elif self.attribute_name == "dynamic":
return_type = self.return_type
if return_type is None:
return_type = "string"
return self._jinja_to_function( return self._jinja_to_function(
"jinja_to_function", "jinja_to_function",
"string", return_type,
True, True,
objectspace, objectspace,
) )
@ -833,7 +847,10 @@ class VariablePropertyCalculation(_VariableCalculation):
when = [] when = []
else: else:
if variable.type != "boolean": if variable.type != "boolean":
raise Exception("only boolean!") msg = _(
'"when" or "when_not" is mandatory for the not boolean variable "{0}" in attribute "{1}"'
).format(self.path, self.attribute_name)
raise DictConsistencyError(msg, 106, variable.xmlfiles)
when = True when = True
inverse = False inverse = False
params["when"] = when params["when"] = when
@ -1076,6 +1093,7 @@ class Variable(BaseModel):
unique: Optional[bool] = None unique: Optional[bool] = None
hidden: Union[bool, Calculation] = False hidden: Union[bool, Calculation] = False
disabled: Union[bool, Calculation] = False disabled: Union[bool, Calculation] = False
frozen: Union[bool, Calculation] = False
# others # others
path: str path: str
namespace: Optional[str] namespace: Optional[str]

View file

@ -82,15 +82,15 @@ class TiramisuReflector:
continue continue
self.text["header"].append(f"load_functions('{funcs_path}')") self.text["header"].append(f"load_functions('{funcs_path}')")
if self.objectspace.export_with_import: if self.objectspace.export_with_import:
if self.objectspace.has_namespace: # if self.objectspace.has_namespace:
self.text["header"].extend( self.text["header"].extend(
[ [
"try:", "try:",
" groups.namespace", " groups.namespace",
"except:", "except:",
" groups.addgroup('namespace')", " groups.addgroup('namespace')",
] ]
) )
for mode in self.objectspace.modes_level: for mode in self.objectspace.modes_level:
self.text["header"].append(f'ALLOWED_LEADER_PROPERTIES.add("{mode}")') self.text["header"].append(f'ALLOWED_LEADER_PROPERTIES.add("{mode}")')
self.make_tiramisu_objects() self.make_tiramisu_objects()
@ -338,11 +338,18 @@ class Common:
"""build variable parameters""" """build variable parameters"""
variable = param["variable"] variable = param["variable"]
whole = param.get("whole", False) whole = param.get("whole", False)
dynamic = param.get("dynamic", True)
if variable.path == self.elt.path: if variable.path == self.elt.path:
return f"ParamSelfOption(whole={whole})" ret = f"ParamSelfOption(whole={whole}"
if not dynamic:
ret += ", dynamic=False"
return ret + ')'
if whole: if whole:
msg = f'variable param "{variable.path}" has whole attribute but it\'s not allowed for external variable' msg = _('variable param "{0}" has whole attribute but it\'s not allowed for external variable')
raise DictConsistencyError(msg, 34, self.elt.xmlfiles) raise DictConsistencyError(msg.format(variable.path), 34, self.elt.xmlfiles)
if not dynamic:
msg = _('variable param "{0}" has dynamic attribute but it\'s not allowed for external variable')
raise DictConsistencyError(msg.format(variable.path), 34, self.elt.xmlfiles)
option_name = self.tiramisu.reflector_objects[variable.path].get( option_name = self.tiramisu.reflector_objects[variable.path].get(
self.calls, self.elt.path self.calls, self.elt.path
) )

View file

@ -59,6 +59,7 @@ class Annotator(Walk):
return return
alternative_name = variable.alternative_name alternative_name = variable.alternative_name
variable_path = variable.path variable_path = variable.path
self.objectspace.informations.add(variable_path, "alternative_name", alternative_name)
all_letters = "" all_letters = ""
for letter in alternative_name: for letter in alternative_name:
all_letters += letter all_letters += letter

View file

@ -33,7 +33,7 @@ structural_commandline:
default: true default: true
""" """
return { return {
"name": "cmdline", "name": "commandline",
"process": "structural", "process": "structural",
"options": options, "options": options,
"level": 20, "level": 20,

View file

@ -141,12 +141,12 @@ class Walker:
"""Parse file""" """Parse file"""
with open(filename, encoding="utf8") as file_fh: with open(filename, encoding="utf8") as file_fh:
objects = self.yaml.load(file_fh) objects = self.yaml.load(file_fh)
if objects is None:
return
version = self.convert.validate_file_version( version = self.convert.validate_file_version(
objects, objects,
filename, filename,
) )
if objects is None:
return
self.convert.parse_root_file( self.convert.parse_root_file(
filename, filename,
path, path,

View file

@ -28,6 +28,17 @@ def get_rougail_config(
else: else:
main_namespace_default = "null" main_namespace_default = "null"
options = f""" options = f"""
main_namespace:
description: {_("Main namespace name")}
default: {main_namespace_default}
alternative_name: s
mandatory: false
disabled:
jinja: >-
{{{{ 'directory' not in _.step.structural and 'string' not in _.step.structural }}}}
return_type: boolean
description: {_('directory or string is not in "_.step.structural"')}
main_structural_directories: main_structural_directories:
description: {_("Directories where structural files are placed")} description: {_("Directories where structural files are placed")}
type: unix_filename type: unix_filename
@ -54,32 +65,21 @@ sort_structural_files_all:
directory is not in _.step.structural directory is not in _.step.structural
{{% endif %}} {{% endif %}}
main_namespace:
description: {_("Main namespace name")}
default: {main_namespace_default}
alternative_name: s
mandatory: false
disabled:
jinja: >-
{{{{ 'directory' not in _.step.structural }}}}
return_type: boolean
description: directory is not in _.step.structural
isolated_namespace: isolated_namespace:
description: {_("Namespaces are isolated")} description: {_("Namespaces are isolated")}
default: true default: true
disabled: disabled:
jinja: >- jinja: >-
{{{{ 'directory' not in _.step.structural or not _.main_namespace }}}} {{{{ 'directory' not in _.step.structural and 'string' not in _.step.structural }}}}
return_type: boolean return_type: boolean
description: directory is not in _.step.structural or main_namespace is not set description: {_('directory or string is not in "_.step.structural" or "_.main_namespace" is not set')}
extra_namespaces: extra_namespaces:
description: {_("Extra namespaces")} description: {_("Extra namespaces")}
type: leadership type: leadership
disabled: disabled:
jinja: >- jinja: >-
{{{{ 'directory' not in _.step.structural or not _.main_namespace }}}} {{{{ ('directory' not in _.step.structural and 'string' not in _.step.structural) or not _.main_namespace }}}}
return_type: boolean return_type: boolean
description: directory is not in _.step.structural or main_namespace is not set description: directory is not in _.step.structural or main_namespace is not set
@ -99,6 +99,11 @@ extra_namespaces:
types: types:
- directory - directory
multi: true multi: true
disabled:
jinja: >-
{{{{ 'directory' not in __.step.structural }}}}
return_type: boolean
description: {_('directory is not in "__.step.structural"')}
""" """
return { return {
"name": "directory", "name": "directory",

View file

@ -82,54 +82,127 @@ def convert_boolean(value: str) -> bool:
return None return None
raise Exception(_('unknown boolean value "{0}"').format(value)) raise Exception(_('unknown boolean value "{0}"').format(value))
_ip_params = {
"cidr": {"description": _("IP must be in CIDR format")},
"private_only": {"description": _("private IP are allowed")},
"allow_reserved": {"description": _("reserved IP are allowed")},
}
_network_params = {
"cidr": {"description": _("network must be in CIDR format")},
"private_only": {"description": _("private network are allowed")},
"allow_reserved": {"description": _("reserved network are allowed")},
}
_port_params = {
"allow_range": {"description": _("can be range of port")},
"allow_protocol": {"description": _("can have the protocol")},
"allow_zero": {"description": _("port 0 is allowed")},
"allow_wellknown": {"description": _("well-known ports (1 to 1023) are allowed")},
"allow_registred": {"description": _("registred ports (1024 to 49151) are allowed")},
"allow_private": {"description": _("private ports (greater than 49152) are allowed")},
}
_domain_params = {
"type": {"description": _("type of domainname"), "choices": ('domainname', 'netbios', 'hostname'), 'doc': _("type {0}")},
"allow_startswith_dot": {"description": _("the domain name can starts by a dot")},
"allow_without_dot": {"description": _("the domain name can be a hostname")},
"allow_ip": {"description": _("the domain name can be an IP")},
"allow_cidr_network": {"description": _("the domain name can be network in CIDR format")},
"test_existence": {"description": _("the domain name must exist")},
}
_web_params = _port_params | _domain_params
CONVERT_OPTION = { CONVERT_OPTION = {
"string": dict(opttype="StrOption", example="example"), "string": dict(opttype="StrOption", example="example"),
"number": dict(opttype="IntOption", func=int, example=42), "number": dict(opttype="IntOption",
"integer": dict(opttype="IntOption", func=int, example=42), func=int,
params={
"min_number": {"description": _("the minimum value"), 'doc': _("the minimum value is {0}")},
"max_number": {"description": _("the maximum value"), 'doc': _("the maximum value is {0}")},
},
example=42),
"integer": dict(opttype="IntOption",
params={
"min_integer": {"description": _("the minimum value"), 'doc': _("the minimum value is {0}")},
"max_integer": {"description": _("the maximum value"), 'doc': _("the maximum value is {0}")},
},
func=int,
example=42,
),
"float": dict(opttype="FloatOption", func=float, example=1.42), "float": dict(opttype="FloatOption", func=float, example=1.42),
"boolean": dict(opttype="BoolOption", func=convert_boolean), "boolean": dict(opttype="BoolOption", func=convert_boolean),
"secret": dict(opttype="PasswordOption", example="secrets"), "secret": dict(opttype="PasswordOption",
params={
"min_len": {"description": _("minimum characters length for the secret"), "doc": _("minimum length for the secret is {0} characters")},
"max_len": {"description": _("maximum characters length for the secret"), "doc": _("maximum length for the secret is {0} characters")},
"forbidden_char": {"description": _("forbidden characters"), "doc": _("forbidden characters: {0}")},
},
example="secrets"),
"mail": dict(opttype="EmailOption", example="user@example.net"), "mail": dict(opttype="EmailOption", example="user@example.net"),
"unix_filename": dict(opttype="FilenameOption", example="/tmp/myfile.txt"), "unix_filename": dict(opttype="FilenameOption",
msg="UNIX filename",
params={
"allow_relative": {"description": _("this filename could be a relative path")},
"test_existence": {"description": _("this file must exist")},
"types": {"description": _("file type allowed"), "doc": _("file type allowed: {0}"), "choices": ("file", "directory"), "multi": True},
},
example="/tmp/myfile.txt"),
"date": dict(opttype="DateOption", example="2000-01-01"), "date": dict(opttype="DateOption", example="2000-01-01"),
"unix_user": dict(opttype="UsernameOption", example="username"), "unix_user": dict(opttype="UsernameOption", example="username",
msg="UNIX user"
),
"ip": dict( "ip": dict(
opttype="IPOption", initkwargs={"allow_reserved": True}, example="1.1.1.1" opttype="IPOption", initkwargs={"allow_reserved": True},
msg="IP",
params=_ip_params,
example="1.1.1.1"
), ),
"cidr": dict(opttype="IPOption", initkwargs={"cidr": True}, example="1.1.1.0/24"), "cidr": dict(opttype="IPOption", msg="CIDR", initkwargs={"cidr": True},
params=_ip_params,
example="1.1.1.0/24"),
"netmask": dict(opttype="NetmaskOption", example="255.255.255.0"), "netmask": dict(opttype="NetmaskOption", example="255.255.255.0"),
"network": dict(opttype="NetworkOption", example="1.1.1.0"), "network": dict(opttype="NetworkOption",
params=_network_params,
example="1.1.1.0"),
"network_cidr": dict( "network_cidr": dict(
opttype="NetworkOption", initkwargs={"cidr": True}, example="1.1.1.0/24" opttype="NetworkOption", initkwargs={"cidr": True}, example="1.1.1.0/24",
params=_network_params,
msg="network CIDR",
), ),
"broadcast": dict(opttype="BroadcastOption", example="1.1.1.255"), "broadcast": dict(opttype="BroadcastOption", example="1.1.1.255"),
"netbios": dict( "netbios": dict(
opttype="DomainnameOption", opttype="DomainnameOption",
initkwargs={"type": "netbios", "warnings_only": True}, initkwargs={"type": "netbios", "warnings_only": True},
params=_domain_params,
example="example", example="example",
), ),
"domainname": dict( "domainname": dict(
opttype="DomainnameOption", opttype="DomainnameOption",
initkwargs={"type": "domainname", "allow_ip": False}, initkwargs={"type": "domainname", "allow_ip": False},
params=_domain_params,
example="example.net", example="example.net",
), ),
"hostname": dict( "hostname": dict(
opttype="DomainnameOption", opttype="DomainnameOption",
initkwargs={"type": "hostname", "allow_ip": False}, initkwargs={"type": "hostname", "allow_ip": False},
params=_domain_params,
example="example", example="example",
), ),
"web_address": dict( "web_address": dict(
opttype="URLOption", opttype="URLOption",
initkwargs={"allow_ip": False, "allow_without_dot": True}, initkwargs={"allow_ip": False, "allow_without_dot": True},
msg="web address",
params=_web_params,
example="https://example.net", example="https://example.net",
), ),
"port": dict( "port": dict(
opttype="PortOption", initkwargs={"allow_private": True}, example="111", func=str, opttype="PortOption", initkwargs={"allow_private": True},
params=_port_params,
example="111", func=str,
), ),
"mac": dict(opttype="MACOption", example="00:00:00:00:00"), "mac": dict(opttype="MACOption", example="00:00:00:00:00"),
"unix_permissions": dict( "unix_permissions": dict(
opttype="PermissionsOption", opttype="PermissionsOption",
msg="UNIX permissions",
initkwargs={"warnings_only": True}, initkwargs={"warnings_only": True},
func=int, func=int,
example="644", example="644",
@ -159,7 +232,7 @@ def raise_carry_out_calculation_error(subconfig, *args, **kwargs):
ymlfiles = subconfig.config_bag.context.get_values().get_information( ymlfiles = subconfig.config_bag.context.get_values().get_information(
subconfig, "ymlfiles", [] subconfig, "ymlfiles", []
) )
raise ConfigError(_("{0} in {1}").format(err, display_xmlfiles(ymlfiles))) raise ConfigError(_("{0} in {1}").format(err, display_xmlfiles(ymlfiles)), subconfig=subconfig)
errors.raise_carry_out_calculation_error = raise_carry_out_calculation_error errors.raise_carry_out_calculation_error = raise_carry_out_calculation_error
@ -168,6 +241,7 @@ errors.raise_carry_out_calculation_error = raise_carry_out_calculation_error
global func global func
dict_env = {} dict_env = {}
ENV = SandboxedEnvironment(loader=DictLoader(dict_env), undefined=StrictUndefined) ENV = SandboxedEnvironment(loader=DictLoader(dict_env), undefined=StrictUndefined)
ENV.add_extension('jinja2.ext.do')
func = ENV.filters func = ENV.filters
ENV.compile_templates("jinja_caches", zip=None) ENV.compile_templates("jinja_caches", zip=None)
@ -241,20 +315,8 @@ def tiramisu_display_name(
with_quote: bool = False, with_quote: bool = False,
) -> str: ) -> str:
"""Replace the Tiramisu display_name function to display path + description""" """Replace the Tiramisu display_name function to display path + description"""
config_bag = subconfig.config_bag def get_path():
context = config_bag.context if description_type in ["description", "name", "name_and_description"]:
values = context.get_values()
context_subconfig = context.get_root(config_bag)
doc = values.get_information(subconfig, "doc", None)
comment = doc if doc and doc != kls.impl_getname() else ""
if "{{ identifier }}" in comment and subconfig.identifiers:
comment = comment.replace("{{ identifier }}", str(subconfig.identifiers[-1]))
path_in_description = values.get_information(
context_subconfig, "path_in_description", True
)
if path_in_description or not comment:
comment = f" ({comment})" if comment else ""
if path_in_description is False:
path = kls.impl_getname() path = kls.impl_getname()
else: else:
path = kls.impl_getpath() path = kls.impl_getpath()
@ -262,12 +324,40 @@ def tiramisu_display_name(
path = path.replace( path = path.replace(
"{{ identifier }}", normalize_family(str(subconfig.identifiers[-1])) "{{ identifier }}", normalize_family(str(subconfig.identifiers[-1]))
) )
return path
config_bag = subconfig.config_bag
context = config_bag.context
values = context.get_values()
context_subconfig = context.get_root(config_bag)
description_type = values.get_information(
context_subconfig, "description_type", "name_and_description"
)
if description_type in ["description", "name_and_description"]:
doc = values.get_information(subconfig, "doc", None)
description = doc if doc and doc != kls.impl_getname() else ""
if "{{ identifier }}" in description and subconfig.identifiers:
description = description.replace("{{ identifier }}", str(subconfig.identifiers[-1]))
if description_type in ["name", "path", "name_and_description"]:
path = get_path()
if description_type == "name_and_description":
if description:
if with_quote:
description = f'"{path}" ({description})'
else:
description = f"{path} ({description})"
else:
if with_quote:
description = f'"{path}"'
else:
description = path
else: else:
path = comment if description_type in ["name", "path"]:
comment = "" description = path
if with_quote: elif not description:
return f'"{path}"{comment}' description = get_path()
return f"{path}{comment}" if with_quote:
description = f'"{description}"'
return description
def rougail_calc_value(*args, __default_value=None, __internal_multi=False, **kwargs): def rougail_calc_value(*args, __default_value=None, __internal_multi=False, **kwargs):
@ -307,8 +397,20 @@ def jinja_to_function(
global ENV, CONVERT_OPTION global ENV, CONVERT_OPTION
kw = {} kw = {}
for key, value in kwargs.items(): for key, value in kwargs.items():
if isinstance(value, PropertiesOptionError): if isinstance(value, list):
value = JinjaError(value) val = []
for v in value:
if isinstance(v, PropertiesOptionError):
v = JinjaError(v)
if v is None:
v = ''
val.append(v)
value = val
else:
if isinstance(value, PropertiesOptionError):
value = JinjaError(value)
if value is None:
value = ''
if "." in key: if "." in key:
c_kw = kw c_kw = kw
path, var = key.rsplit(".", 1) path, var = key.rsplit(".", 1)
@ -331,17 +433,14 @@ def jinja_to_function(
values = ENV.get_template(__internal_jinja).render(kw, **func).strip() values = ENV.get_template(__internal_jinja).render(kw, **func).strip()
except Exception as err: except Exception as err:
kw_str = ", ".join(kw_to_string(kw)) kw_str = ", ".join(kw_to_string(kw))
raise ConfigError( prefix = _('cannot calculate the variable "{0}"').format(__internal_variable)
_( msg = _('the attribute "{0}" in {1} with the parameters "{2}" causes the error: {3}').format(
'cannot calculating "{0}" attribute for variable "{1}" in {2} with parameters "{3}": {4}'
).format(
__internal_attribute, __internal_attribute,
__internal_variable,
display_xmlfiles(__internal_files), display_xmlfiles(__internal_files),
kw_str, kw_str,
err, err,
) )
) from err raise ConfigError(msg, prefix=prefix) from err
convert = CONVERT_OPTION[__internal_type].get("func", str) convert = CONVERT_OPTION[__internal_type].get("func", str)
if __internal_multi: if __internal_multi:
values = [ values = [
@ -353,9 +452,15 @@ def jinja_to_function(
try: try:
values = convert(values) values = convert(values)
except Exception as err: except Exception as err:
raise ConfigError( prefix = _('cannot converting the variable "{0}"').format(__internal_variable)
f'cannot converting "{__internal_attribute}" attribute for variable "{__internal_variable}" in {display_xmlfiles(__internal_files)}: {err}' msg = _('"{0}" is an invalid {1}').format(values, __internal_type)
) from err if __internal_attribute != "default":
msg = _('the attribute "{0}" in {1} causes the error: {2}').format(
__internal_attribute,
display_xmlfiles(__internal_files),
msg,
)
raise ConfigError(msg, prefix=prefix) from err
values = values if values != "" and values != "None" else None values = values if values != "" and values != "None" else None
if values is None and __default_value is not None: if values is None and __default_value is not None:
return __default_value return __default_value