Fixed missing Set_Text_Variables valid keys

This commit is contained in:
Salvador E. Tropea 2022-03-31 14:50:25 -03:00
parent 372fad5d28
commit 1a73dd5e29
2 changed files with 12 additions and 0 deletions

View File

@ -181,6 +181,14 @@ This section is used to specify tasks that will be executed before generating an
They are expanded using ${VARIABLE}, and stored in the project file.
This preflight replaces `pcb_replace` and `sch_replace` when using KiCad 6.
The KiCad project file is modified.
* Valid keys:
- `after`: [string=''] Text to add after the output of `command`.
- `before`: [string=''] Text to add before the output of `command`.
- `command`: [string=''] Command to execute to get the text, will be used only if `text` is empty.
- `expand_kibot_patterns`: [boolean=true] Expand %X patterns. The context is `schematic`.
- `name`: [string=''] Name of the variable. The `version` variable will be expanded using `${version}`.
- `text`: [string=''] Text to insert instead of the variable.
- *variable*: Alias for name.
- `update_qr`: [boolean=false] Update the QR codes.
Complements the `qr_lib` output.
The KiCad 6 files and the KiCad 5 PCB needs manual update, generating a new library isn't enough.

View File

@ -73,6 +73,10 @@ class Set_Text_Variables(BasePreFlight): # noqa: F821
f.config(self)
super().__init__(name, f.variables)
@classmethod
def get_doc(cls):
return cls.__doc__, KiCadVariable
@classmethod
def get_example(cls):
""" Returns a YAML value for the example config """