diff options
author | Dominique Martinet <asmadeus@codewreck.org> | 2017-12-29 15:31:04 +0100 |
---|---|---|
committer | Dominique Martinet <asmadeus@codewreck.org> | 2018-01-05 15:36:20 +0100 |
commit | c83900593daace2ef85174163edf2748179e28f2 (patch) | |
tree | 40cdc706c8b1439d630c6b514817c8e6f0b4e4fd /sway/commands.c | |
parent | Merge pull request #1552 from martinetd/cleanup (diff) | |
download | sway-c83900593daace2ef85174163edf2748179e28f2.tar.gz sway-c83900593daace2ef85174163edf2748179e28f2.tar.zst sway-c83900593daace2ef85174163edf2748179e28f2.zip |
config: add 'set' command
Diffstat (limited to 'sway/commands.c')
-rw-r--r-- | sway/commands.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sway/commands.c b/sway/commands.c index c1c6dc5d..f01329db 100644 --- a/sway/commands.c +++ b/sway/commands.c | |||
@@ -138,6 +138,7 @@ static struct cmd_handler handlers[] = { | |||
138 | { "input", cmd_input }, | 138 | { "input", cmd_input }, |
139 | { "output", cmd_output }, | 139 | { "output", cmd_output }, |
140 | { "seat", cmd_seat }, | 140 | { "seat", cmd_seat }, |
141 | { "set", cmd_set }, | ||
141 | }; | 142 | }; |
142 | 143 | ||
143 | static int handler_compare(const void *_a, const void *_b) { | 144 | static int handler_compare(const void *_a, const void *_b) { |
@@ -290,7 +291,7 @@ struct cmd_results *config_command(char *exec, enum cmd_status block) { | |||
290 | int i; | 291 | int i; |
291 | // Var replacement, for all but first argument of set | 292 | // Var replacement, for all but first argument of set |
292 | // TODO commands | 293 | // TODO commands |
293 | for (i = /*handler->handle == cmd_set ? 2 :*/ 1; i < argc; ++i) { | 294 | for (i = handler->handle == cmd_set ? 2 : 1; i < argc; ++i) { |
294 | argv[i] = do_var_replacement(argv[i]); | 295 | argv[i] = do_var_replacement(argv[i]); |
295 | unescape_string(argv[i]); | 296 | unescape_string(argv[i]); |
296 | } | 297 | } |