mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-29 05:40:27 -04:00
conf: handle array of arguments in context.exec
We handeled "arg1 arg2 ... " before and used to split between spaces to get the arguments for execvp but that doesn't work so well when there are arguments with spaces. Instead use JSON parsing to get the array of arguments. This make it possible to use [ arg1 arg2 .. ] and quote each arg separately. You can still use the old method and even double escape: "\"arg1\" \"arg2 with spaces\"" or [ "arg1" "arg2 with spaces" ]
This commit is contained in:
parent
4a19a76dc1
commit
7f4a0ba8cb
4 changed files with 51 additions and 18 deletions
|
|
@ -413,7 +413,7 @@ part of the initialization of the PipeWire program.
|
|||
```json
|
||||
context.exec = [
|
||||
#{ path = <program-name>
|
||||
# ( args = "<arguments>" )
|
||||
# ( args = "<arguments>" | [ <arg1> <arg2> ... ] )
|
||||
# ( condition = [ { <key> = <value> ... } ... ] )
|
||||
#}
|
||||
]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue