[pp:exec] implement 'commands' option

to run multiple commands in succession
and stopping if one fails
This commit is contained in:
Mike Fährmann
2025-06-13 20:19:01 +02:00
parent 9d3cf67f3e
commit fa1fc39a36
3 changed files with 93 additions and 16 deletions

View File

@@ -6717,6 +6717,25 @@ Description
and ``{_filename}``.
exec.commands
-------------
Type
``list`` of `commands <exec.command_>`__
Example
.. code:: json
[
["echo", "{user[account]}", "{id}"]
["magick", "convert" "{_path}", "\fF {_path.rpartition('.')[0]}.png"],
"rm {}",
]
Description
Multiple `commands <exec.command_>`__ to run in succession.
All `commands <exec.command_>`__ after the first returning with a non-zero
exit status will not be run.
exec.event
----------
Type