Compare commits
2 commits
cb770dd8d7
...
a0843e08ca
| Author | SHA1 | Date | |
|---|---|---|---|
| a0843e08ca | |||
| c1ab106ba5 |
28 changed files with 546 additions and 20 deletions
|
|
@ -119,27 +119,38 @@ class RougailOutputDoc(Examples, Changelog):
|
|||
print(data)
|
||||
return ret
|
||||
|
||||
def load(self, reload=False):
|
||||
def load(self):
|
||||
self.dynamic_paths = {}
|
||||
config = self.conf.unrestraint
|
||||
self._populate_dynamics(config, reload)
|
||||
self.populate_dynamics(config=config)
|
||||
informations = self.parse_families(config)
|
||||
if informations is None:
|
||||
informations = {}
|
||||
self.informations = informations
|
||||
|
||||
def _populate_dynamics(self, family, reload) -> None:
|
||||
for child in family.list():
|
||||
def populate_dynamics(self, *, config=None, reload=False):
|
||||
if config is None:
|
||||
config = self.conf.unrestraint
|
||||
self._populate_dynamics(config, reload)
|
||||
|
||||
def _populate_dynamics(self, family, reload, uncalculated=False) -> None:
|
||||
def populate(child, uncalculated):
|
||||
if child.isoptiondescription():
|
||||
type_ = "family"
|
||||
else:
|
||||
type_ = "variable"
|
||||
if child.isdynamic():
|
||||
self.populate_dynamic(child, type_, reload)
|
||||
if child.isoptiondescription():
|
||||
self._populate_dynamics(child, reload)
|
||||
self.populate_dynamic(child, type_, reload, uncalculated)
|
||||
if not uncalculated and child.isoptiondescription():
|
||||
self._populate_dynamics(child, reload, uncalculated)
|
||||
for child in family.list(uncalculated=uncalculated):
|
||||
populate(child, uncalculated)
|
||||
if not uncalculated:
|
||||
for child in family.list(uncalculated=True):
|
||||
if child.isdynamic() and child.path(uncalculated=True) not in self.dynamic_paths:
|
||||
populate(family, uncalculated=True)
|
||||
|
||||
def populate_dynamic(self, obj, type_, reload) -> None:
|
||||
def populate_dynamic(self, obj, type_, reload, uncalculated) -> None:
|
||||
path = obj.path(uncalculated=True)
|
||||
if path not in self.dynamic_paths:
|
||||
new_name = True
|
||||
|
|
@ -158,6 +169,8 @@ class RougailOutputDoc(Examples, Changelog):
|
|||
self.dynamic_paths[path]["description"] = self._convert_description(
|
||||
description, obj, type_, its_a_path=True
|
||||
)
|
||||
if uncalculated:
|
||||
return
|
||||
dynamic_obj = self.dynamic_paths[path]
|
||||
if reload and obj.identifiers() in dynamic_obj["identifiers"]:
|
||||
return
|
||||
|
|
@ -168,7 +181,7 @@ class RougailOutputDoc(Examples, Changelog):
|
|||
informations = {}
|
||||
leader = None
|
||||
for child in family.list():
|
||||
if self._is_inaccessible_user_data(child):
|
||||
if self.is_inaccessible_user_data(child):
|
||||
continue
|
||||
if child.type(only_self=True) == "symlink":
|
||||
continue
|
||||
|
|
@ -178,7 +191,7 @@ class RougailOutputDoc(Examples, Changelog):
|
|||
self.parse_family(child, informations)
|
||||
return informations
|
||||
|
||||
def _is_inaccessible_user_data(self, child):
|
||||
def is_inaccessible_user_data(self, child):
|
||||
"""If family is not accessible in read_write mode (to load user_data),
|
||||
do not comment this family
|
||||
"""
|
||||
|
|
@ -199,7 +212,7 @@ class RougailOutputDoc(Examples, Changelog):
|
|||
uncalculated = variable.value.get(uncalculated=True)
|
||||
if (
|
||||
not isinstance(uncalculated, Calculation)
|
||||
and self._is_inaccessible_user_data(variable)
|
||||
and self.is_inaccessible_user_data(variable)
|
||||
and (
|
||||
condition == "when"
|
||||
and value == variable_value
|
||||
|
|
@ -214,11 +227,11 @@ class RougailOutputDoc(Examples, Changelog):
|
|||
return True
|
||||
return False
|
||||
|
||||
def parse_family(self, family, informations: dict) -> None:
|
||||
def parse_family(self, family, informations: dict, *, force_injection=False) -> None:
|
||||
path = family.path(uncalculated=True)
|
||||
name = family.name(uncalculated=True)
|
||||
sub_informations = self.parse_families(family)
|
||||
if not sub_informations:
|
||||
if not force_injection and not sub_informations:
|
||||
return
|
||||
# if self.with_family:
|
||||
family_informations = self._populate_family(
|
||||
|
|
@ -709,7 +722,7 @@ class RougailOutputDoc(Examples, Changelog):
|
|||
if prop in HIDDEN_PROPERTIES:
|
||||
return False
|
||||
variable = None
|
||||
if variable and self._is_inaccessible_user_data(variable):
|
||||
if variable and self.is_inaccessible_user_data(variable):
|
||||
try:
|
||||
variable_value = self._get_unmodified_default_value(variable)
|
||||
except VariableCalculationDependencyError:
|
||||
|
|
@ -779,7 +792,7 @@ class RougailOutputDoc(Examples, Changelog):
|
|||
cpath = calc_path(path, identifiers=identifiers)
|
||||
if regexp and not regexp.search(cpath):
|
||||
continue
|
||||
if self._is_inaccessible_user_data(self.conf.option(cpath)):
|
||||
if self.is_inaccessible_user_data(self.conf.option(cpath)):
|
||||
if all_is_undocumented is None:
|
||||
all_is_undocumented = True
|
||||
msg = hidden_msg
|
||||
|
|
@ -806,7 +819,7 @@ class RougailOutputDoc(Examples, Changelog):
|
|||
except AttributeError as err:
|
||||
pass
|
||||
else:
|
||||
if not isfollower and self._is_inaccessible_user_data(variable):
|
||||
if not isfollower and self.is_inaccessible_user_data(variable):
|
||||
try:
|
||||
uncalculated = variable.value.get(uncalculated=True)
|
||||
except PropertiesOptionError:
|
||||
|
|
@ -845,6 +858,6 @@ class RougailOutputDoc(Examples, Changelog):
|
|||
return child.value.get()
|
||||
if calculation["type"] == "variable":
|
||||
variable = self.conf.forcepermissive.option(calculation["value"])
|
||||
if variable and self._is_inaccessible_user_data(variable):
|
||||
if variable and self.is_inaccessible_user_data(variable):
|
||||
return self._get_unmodified_default_value(variable)
|
||||
raise VariableCalculationDependencyError()
|
||||
|
|
|
|||
|
|
@ -808,7 +808,11 @@ class CommonFormater:
|
|||
submessage, msg = self.message_to_string(msg, submessage)
|
||||
if isinstance(msg, list):
|
||||
if len(msg) == 1:
|
||||
msg = calc_path(msg[0], self)
|
||||
submessage, elt = self.message_to_string(msg[0], submessage)
|
||||
if isinstance(elt, list):
|
||||
submessage += self.list(elt)
|
||||
else:
|
||||
submessage += elt
|
||||
else:
|
||||
lst = []
|
||||
for p in msg:
|
||||
|
|
|
|||
26
tests/results/test/60_0family_dynamic_source_hidden.adoc
Normal file
26
tests/results/test/60_0family_dynamic_source_hidden.adoc
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
== A dynamic family
|
||||
|
||||
This family builds families dynamically.
|
||||
|
||||
|
||||
**dyn__val1__** +
|
||||
**dyn__val2__**
|
||||
|
||||
`basic`
|
||||
|
||||
**Identifiers**: (from an undocumented variable)
|
||||
|
||||
* val1
|
||||
* val2
|
||||
|
||||
[cols="1a,1a"]
|
||||
|====
|
||||
| Variable | Description
|
||||
|
|
||||
|
||||
**dyn__val1__.var** +
|
||||
**dyn__val2__.var** +
|
||||
`https://rougail.readthedocs.io/en/latest/variable.html#variables-types[string]` `basic` `mandatory` |
|
||||
A dynamic variable.
|
||||
|====
|
||||
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
<details><summary>A dynamic family</summary>
|
||||
|
||||
This family builds families dynamically.
|
||||
|
||||
>>> [!note] Informations
|
||||
**dyn*val1***<br/>**dyn*val2***<br>`basic`
|
||||
|
||||
**Identifiers**: (from an undocumented variable)<br/>- val1<br/>- val2
|
||||
>>>
|
||||
| Variable | Description |
|
||||
|----------------------------------------------------------------------------------------------------------------------------------------------------|---------------------|
|
||||
| **dyn*val1*.var**<br/>**dyn*val2*.var**<br/>[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` | A dynamic variable. |
|
||||
|
||||
</details>
|
||||
|
||||
20
tests/results/test/60_0family_dynamic_source_hidden.html
Normal file
20
tests/results/test/60_0family_dynamic_source_hidden.html
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
<h1>A dynamic family</h1>
|
||||
|
||||
This family builds families dynamically.
|
||||
|
||||
<b>dyn<i>val1</i></b><br/><b>dyn<i>val2</i></b>
|
||||
|
||||
<mark>basic</mark>
|
||||
|
||||
<b>Identifiers</b>: (from an undocumented variable)<ul><li>val1</li>
|
||||
<li>val2</li></ul>
|
||||
|
||||
<table>
|
||||
<thead>
|
||||
<tr><th>Variable </th><th>Description </th></tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr><td><b>dyn<i>val1</i>.var</b><br/><b>dyn<i>val2</i>.var</b><br/><mark><a href='https://rougail.readthedocs.io/en/latest/variable.html#variables-types'>string</a></mark> <mark>basic</mark> <mark>mandatory</mark></td><td>A dynamic variable.</td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
72
tests/results/test/60_0family_dynamic_source_hidden.json
Normal file
72
tests/results/test/60_0family_dynamic_source_hidden.json
Normal file
|
|
@ -0,0 +1,72 @@
|
|||
{
|
||||
"dyn{{ identifier }}": {
|
||||
"type": "dynamic",
|
||||
"informations": {
|
||||
"names": [
|
||||
"dynval1",
|
||||
"dynval2"
|
||||
],
|
||||
"identifiers": [
|
||||
[
|
||||
"val1"
|
||||
],
|
||||
[
|
||||
"val2"
|
||||
]
|
||||
],
|
||||
"path": "dyn{{ identifier }}",
|
||||
"description": "A dynamic family",
|
||||
"properties": [
|
||||
{
|
||||
"type": "mode",
|
||||
"name": "basic"
|
||||
}
|
||||
],
|
||||
"identifier": [
|
||||
{
|
||||
"submessage": "(from an undocumented variable)",
|
||||
"values": [
|
||||
"val1",
|
||||
"val2"
|
||||
]
|
||||
}
|
||||
],
|
||||
"help": [
|
||||
"This family builds families dynamically."
|
||||
]
|
||||
},
|
||||
"children": {
|
||||
"var": {
|
||||
"names": [
|
||||
"var",
|
||||
"var"
|
||||
],
|
||||
"identifiers": [
|
||||
[
|
||||
"val1"
|
||||
],
|
||||
[
|
||||
"val2"
|
||||
]
|
||||
],
|
||||
"path": "dyn{{ identifier }}.var",
|
||||
"description": "A dynamic variable.",
|
||||
"type": "variable",
|
||||
"properties": [
|
||||
{
|
||||
"type": "type",
|
||||
"name": "string"
|
||||
},
|
||||
{
|
||||
"type": "mode",
|
||||
"name": "basic"
|
||||
},
|
||||
{
|
||||
"type": "property",
|
||||
"name": "mandatory"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
14
tests/results/test/60_0family_dynamic_source_hidden.md
Normal file
14
tests/results/test/60_0family_dynamic_source_hidden.md
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
# A dynamic family
|
||||
|
||||
This family builds families dynamically.
|
||||
|
||||
**dyn*val1***<br/>**dyn*val2***
|
||||
|
||||
`basic`
|
||||
|
||||
**Identifiers**: (from an undocumented variable)<br/>- val1<br/>- val2
|
||||
|
||||
| Variable | Description |
|
||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||
| **dyn*val1*.var**<br/>**dyn*val2*.var**<br/>[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` | A dynamic variable. |
|
||||
|
||||
30
tests/results/test/60_0family_dynamic_source_hidden.sh
Normal file
30
tests/results/test/60_0family_dynamic_source_hidden.sh
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
|
||||
|
||||
[1;4;96mA dynamic family[0m
|
||||
|
||||
|
||||
This family builds families dynamically.
|
||||
|
||||
|
||||
|
||||
[1mdyn[0m[1;3mval1[0m
|
||||
[1mdyn[0m[1;3mval2[0m
|
||||
|
||||
|
||||
[1;7m basic [0m
|
||||
|
||||
|
||||
[1mIdentifiers[0m: [1m([0mfrom an undocumented variable[1m)[0m
|
||||
- val1
|
||||
- val2
|
||||
|
||||
|
||||
|
||||
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
|
||||
┃[1m [0m[1mVariable [0m[1m [0m┃[1m [0m[1mDescription [0m[1m [0m┃
|
||||
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
|
||||
│ [1mdyn[0m[1;3mval1[0m[1m.var[0m │ A dynamic variable. │
|
||||
│ [1mdyn[0m[1;3mval2[0m[1m.var[0m │ │
|
||||
│ [1;7m string [0m [1;7m basic [0m [1;7m mandatory [0m │ │
|
||||
└───────────────────────────────────────┴──────────────────────────────────────┘
|
||||
|
||||
|
|
@ -0,0 +1 @@
|
|||
[]
|
||||
|
|
@ -0,0 +1,18 @@
|
|||
# Example with mandatory variables not filled in
|
||||
|
||||
```yaml
|
||||
---
|
||||
dynval1:
|
||||
var: example
|
||||
dynval2:
|
||||
var: example
|
||||
```
|
||||
# Example with all variables modifiable
|
||||
|
||||
```yaml
|
||||
---
|
||||
dynval1:
|
||||
var: example
|
||||
dynval2:
|
||||
var: example
|
||||
```
|
||||
|
|
@ -0,0 +1 @@
|
|||
[]
|
||||
|
|
@ -0,0 +1,32 @@
|
|||
== Variables for "Rougail"
|
||||
|
||||
**rougail**
|
||||
|
||||
`basic`
|
||||
|
||||
=== A dynamic family
|
||||
|
||||
This family builds families dynamically.
|
||||
|
||||
|
||||
**rougail.dyn__val1__** +
|
||||
**rougail.dyn__val2__**
|
||||
|
||||
`basic`
|
||||
|
||||
**Identifiers**: (from an undocumented variable)
|
||||
|
||||
* val1
|
||||
* val2
|
||||
|
||||
[cols="1a,1a"]
|
||||
|====
|
||||
| Variable | Description
|
||||
|
|
||||
|
||||
**rougail.dyn__val1__.var** +
|
||||
**rougail.dyn__val2__.var** +
|
||||
`https://rougail.readthedocs.io/en/latest/variable.html#variables-types[string]` `basic` `mandatory` |
|
||||
A dynamic variable.
|
||||
|====
|
||||
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
== New variable
|
||||
|
||||
[cols="1a,1a"]
|
||||
|====
|
||||
| Variable | Description
|
||||
|
|
||||
|
||||
**rougail.dyn__val1__.var** +
|
||||
**rougail.dyn__val2__.var** +
|
||||
`https://rougail.readthedocs.io/en/latest/variable.html#variables-types[string]` `basic` `mandatory` |
|
||||
A dynamic variable.
|
||||
|====
|
||||
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
<details><summary>New variable</summary>
|
||||
|
||||
| Variable | Description |
|
||||
|--------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------|
|
||||
| **rougail.dyn*val1*.var**<br/>**rougail.dyn*val2*.var**<br/>[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` | A dynamic variable. |
|
||||
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
<h1>New variable</h1>
|
||||
|
||||
<table>
|
||||
<thead>
|
||||
<tr><th>Variable </th><th>Description </th></tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr><td><b>rougail.dyn<i>val1</i>.var</b><br/><b>rougail.dyn<i>val2</i>.var</b><br/><mark><a href='https://rougail.readthedocs.io/en/latest/variable.html#variables-types'>string</a></mark> <mark>basic</mark> <mark>mandatory</mark></td><td>A dynamic variable.</td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
# New variable
|
||||
|
||||
| Variable | Description |
|
||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||
| **rougail.dyn*val1*.var**<br/>**rougail.dyn*val2*.var**<br/>[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` | A dynamic variable. |
|
||||
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
|
||||
|
||||
[1;4;96mNew variable[0m
|
||||
|
||||
|
||||
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
|
||||
┃[1m [0m[1mVariable [0m[1m [0m┃[1m [0m[1mDescription [0m[1m [0m┃
|
||||
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
|
||||
│ [1mrougail.dyn[0m[1;3mval1[0m[1m.var[0m │ A dynamic variable. │
|
||||
│ [1mrougail.dyn[0m[1;3mval2[0m[1m.var[0m │ │
|
||||
│ [1;7m string [0m [1;7m basic [0m [1;7m mandatory [0m │ │
|
||||
└───────────────────────────────────────┴──────────────────────────────────────┘
|
||||
|
|
@ -0,0 +1,24 @@
|
|||
<details><summary>Rougail</summary>
|
||||
|
||||
>>> [!note] Informations
|
||||
**rougail**<br>`basic`
|
||||
|
||||
|
||||
>>>
|
||||
<details><summary>A dynamic family</summary>
|
||||
|
||||
This family builds families dynamically.
|
||||
|
||||
>>> [!note] Informations
|
||||
**rougail.dyn*val1***<br/>**rougail.dyn*val2***<br>`basic`
|
||||
|
||||
**Identifiers**: (from an undocumented variable)<br/>- val1<br/>- val2
|
||||
>>>
|
||||
| Variable | Description |
|
||||
|--------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------|
|
||||
| **rougail.dyn*val1*.var**<br/>**rougail.dyn*val2*.var**<br/>[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` | A dynamic variable. |
|
||||
|
||||
</details>
|
||||
|
||||
</details>
|
||||
|
||||
|
|
@ -0,0 +1,26 @@
|
|||
<h1>Variables for "Rougail"</h1>
|
||||
|
||||
<b>rougail</b>
|
||||
|
||||
<mark>basic</mark>
|
||||
|
||||
<h2>A dynamic family</h2>
|
||||
|
||||
This family builds families dynamically.
|
||||
|
||||
<b>rougail.dyn<i>val1</i></b><br/><b>rougail.dyn<i>val2</i></b>
|
||||
|
||||
<mark>basic</mark>
|
||||
|
||||
<b>Identifiers</b>: (from an undocumented variable)<ul><li>val1</li>
|
||||
<li>val2</li></ul>
|
||||
|
||||
<table>
|
||||
<thead>
|
||||
<tr><th>Variable </th><th>Description </th></tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr><td><b>rougail.dyn<i>val1</i>.var</b><br/><b>rougail.dyn<i>val2</i>.var</b><br/><mark><a href='https://rougail.readthedocs.io/en/latest/variable.html#variables-types'>string</a></mark> <mark>basic</mark> <mark>mandatory</mark></td><td>A dynamic variable.</td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
|
|
@ -0,0 +1,90 @@
|
|||
{
|
||||
"rougail": {
|
||||
"type": "namespace",
|
||||
"informations": {
|
||||
"path": "rougail",
|
||||
"names": [
|
||||
"rougail"
|
||||
],
|
||||
"description": "Rougail",
|
||||
"properties": [
|
||||
{
|
||||
"type": "mode",
|
||||
"name": "basic"
|
||||
}
|
||||
]
|
||||
},
|
||||
"children": {
|
||||
"dyn{{ identifier }}": {
|
||||
"type": "dynamic",
|
||||
"informations": {
|
||||
"names": [
|
||||
"dynval1",
|
||||
"dynval2"
|
||||
],
|
||||
"identifiers": [
|
||||
[
|
||||
"val1"
|
||||
],
|
||||
[
|
||||
"val2"
|
||||
]
|
||||
],
|
||||
"path": "rougail.dyn{{ identifier }}",
|
||||
"description": "A dynamic family",
|
||||
"properties": [
|
||||
{
|
||||
"type": "mode",
|
||||
"name": "basic"
|
||||
}
|
||||
],
|
||||
"identifier": [
|
||||
{
|
||||
"submessage": "(from an undocumented variable)",
|
||||
"values": [
|
||||
"val1",
|
||||
"val2"
|
||||
]
|
||||
}
|
||||
],
|
||||
"help": [
|
||||
"This family builds families dynamically."
|
||||
]
|
||||
},
|
||||
"children": {
|
||||
"var": {
|
||||
"names": [
|
||||
"var",
|
||||
"var"
|
||||
],
|
||||
"identifiers": [
|
||||
[
|
||||
"val1"
|
||||
],
|
||||
[
|
||||
"val2"
|
||||
]
|
||||
],
|
||||
"path": "rougail.dyn{{ identifier }}.var",
|
||||
"description": "A dynamic variable.",
|
||||
"type": "variable",
|
||||
"properties": [
|
||||
{
|
||||
"type": "type",
|
||||
"name": "string"
|
||||
},
|
||||
{
|
||||
"type": "mode",
|
||||
"name": "basic"
|
||||
},
|
||||
{
|
||||
"type": "property",
|
||||
"name": "mandatory"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,20 @@
|
|||
# Variables for "Rougail"
|
||||
|
||||
**rougail**
|
||||
|
||||
`basic`
|
||||
|
||||
## A dynamic family
|
||||
|
||||
This family builds families dynamically.
|
||||
|
||||
**rougail.dyn*val1***<br/>**rougail.dyn*val2***
|
||||
|
||||
`basic`
|
||||
|
||||
**Identifiers**: (from an undocumented variable)<br/>- val1<br/>- val2
|
||||
|
||||
| Variable | Description |
|
||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||
| **rougail.dyn*val1*.var**<br/>**rougail.dyn*val2*.var**<br/>[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` | A dynamic variable. |
|
||||
|
||||
|
|
@ -0,0 +1,45 @@
|
|||
|
||||
|
||||
[1;4;96mVariables for [0m[1;4;96m"Rougail"[0m
|
||||
|
||||
|
||||
|
||||
[1mrougail[0m
|
||||
|
||||
|
||||
|
||||
[1;7m basic [0m
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
[1;4;92mA dynamic family[0m
|
||||
|
||||
|
||||
This family builds families dynamically.
|
||||
|
||||
|
||||
|
||||
[1mrougail.dyn[0m[1;3mval1[0m
|
||||
[1mrougail.dyn[0m[1;3mval2[0m
|
||||
|
||||
|
||||
[1;7m basic [0m
|
||||
|
||||
|
||||
[1mIdentifiers[0m: [1m([0mfrom an undocumented variable[1m)[0m
|
||||
- val1
|
||||
- val2
|
||||
|
||||
|
||||
|
||||
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
|
||||
┃[1m [0m[1mVariable [0m[1m [0m┃[1m [0m[1mDescription [0m[1m [0m┃
|
||||
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
|
||||
│ [1mrougail.dyn[0m[1;3mval1[0m[1m.var[0m │ A dynamic variable. │
|
||||
│ [1mrougail.dyn[0m[1;3mval2[0m[1m.var[0m │ │
|
||||
│ [1;7m string [0m [1;7m basic [0m [1;7m mandatory [0m │ │
|
||||
└───────────────────────────────────────┴──────────────────────────────────────┘
|
||||
|
||||
|
||||
|
|
@ -0,0 +1 @@
|
|||
[]
|
||||
|
|
@ -0,0 +1,20 @@
|
|||
# Example with mandatory variables not filled in
|
||||
|
||||
```yaml
|
||||
---
|
||||
rougail:
|
||||
dynval1:
|
||||
var: example
|
||||
dynval2:
|
||||
var: example
|
||||
```
|
||||
# Example with all variables modifiable
|
||||
|
||||
```yaml
|
||||
---
|
||||
rougail:
|
||||
dynval1:
|
||||
var: example
|
||||
dynval2:
|
||||
var: example
|
||||
```
|
||||
|
|
@ -0,0 +1 @@
|
|||
[]
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
| Variable | Description |
|
||||
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||
| **rougail.dyn*val1*.var**<br/>**rougail.dyn*val2*.var**<br/>[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` | A dynamic variable. |
|
||||
|
||||
|
|
@ -0,0 +1 @@
|
|||
[]
|
||||
|
|
@ -20,7 +20,7 @@ excludes = [
|
|||
]
|
||||
|
||||
test_ok = get_structures_list(excludes)
|
||||
# test_ok = [HERE.parent.parent / "rougail-tests" / "structures" / "40_0leadership_leader_follower"]
|
||||
#test_ok = [HERE.parent.parent / "rougail-tests" / "structures" / "60_0family_dynamic_source_hidden"]
|
||||
|
||||
os.environ['COLUMNS'] = '80'
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue