mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2025-11-02 09:01:48 -05:00
ucm: add cfg-save command
Allow to save whole (or partial) local UCM alsa library configuration to a file. Syntax (saves key1.key2 sub-tree): Sequence [ cfg-save "/tmp/my-file.conf:key1.key2" ] Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
parent
f821f09727
commit
5e7c507152
4 changed files with 56 additions and 0 deletions
|
|
@ -924,6 +924,16 @@ exec:
|
|||
goto exec;
|
||||
}
|
||||
|
||||
if (strcmp(cmd, "cfg-save") == 0) {
|
||||
curr->type = SEQUENCE_ELEMENT_TYPE_CFGSAVE;
|
||||
err = parse_string_substitute3(uc_mgr, n, &curr->data.cfgsave);
|
||||
if (err < 0) {
|
||||
uc_error("error: sysw requires a string!");
|
||||
return err;
|
||||
}
|
||||
continue;
|
||||
}
|
||||
|
||||
if (strcmp(cmd, "comment") == 0)
|
||||
goto skip;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue