Add `config apply` command

reverse-scroll
nirenjan 2021-11-07 16:06:49 -08:00
parent f2b0110380
commit 7448334824
3 changed files with 16 additions and 6 deletions

View File

@ -292,6 +292,16 @@ static void cmd_config(char *buffer, int *buflen, int argc, char **argv)
return;
}
MATCH(1, "apply") {
if (argc == 2) {
x52d_config_apply();
OK("config", "apply");
} else {
ERR_fmt("Unexpected arguments for 'config apply' command; got %d, expected 2", argc);
}
return;
}
ERR_fmt("Unknown subcommand '%s' for 'config' command", argv[1]);
}

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: libx52 0.2.3\n"
"Report-Msgid-Bugs-To: https://github.com/nirenjan/libx52/issues\n"
"POT-Creation-Date: 2021-11-07 06:24-0800\n"
"POT-Creation-Date: 2021-11-07 16:01-0800\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@ -678,12 +678,12 @@ msgstr ""
msgid "Timed out when polling for command"
msgstr ""
#: daemon/x52d_command.c:354
#: daemon/x52d_command.c:364
#, c-format
msgid "Error reading from client %d: %s"
msgstr ""
#: daemon/x52d_command.c:365
#: daemon/x52d_command.c:375
#, c-format
msgid "Short write to client %d; expected %d bytes, wrote %d bytes"
msgstr ""

View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: libx52 0.2.3\n"
"Report-Msgid-Bugs-To: https://github.com/nirenjan/libx52/issues\n"
"POT-Creation-Date: 2021-11-07 06:24-0800\n"
"POT-Creation-Date: 2021-11-07 16:01-0800\n"
"PO-Revision-Date: 2021-11-04 15:35-0700\n"
"Last-Translator: Nirenjan Krishnan <nirenjan@gmail.com>\n"
"Language-Team: Dummy Language for testing i18n\n"
@ -729,12 +729,12 @@ msgstr "Erroray enwhay ollingpay orfay ommandcay: %s"
msgid "Timed out when polling for command"
msgstr "Imedtay outay enwhay ollingpay orfay ommandcay"
#: daemon/x52d_command.c:354
#: daemon/x52d_command.c:364
#, c-format
msgid "Error reading from client %d: %s"
msgstr "Erroray eadingray omfray ientclay %d: %s"
#: daemon/x52d_command.c:365
#: daemon/x52d_command.c:375
#, c-format
msgid "Short write to client %d; expected %d bytes, wrote %d bytes"
msgstr ""