]> git.sur5r.net Git - i3/i3/commitdiff
Create ws in "move workspace number n" if not existing
authorSebastian Ullrich <sebasti@nullrich.de>
Mon, 20 Aug 2012 10:36:10 +0000 (12:36 +0200)
committerMichael Stapelberg <michael@stapelberg.de>
Wed, 22 Aug 2012 15:08:02 +0000 (17:08 +0200)
fixes #729

src/commands.c

index 9830478f7eeaa94ad97d761cce0727b65bd3e95f..8875b8d2bd93b87fd8f0090aa928756e21176d9f 100644 (file)
@@ -486,14 +486,7 @@ void cmd_move_con_to_workspace_number(I3_CMD, char *which) {
             child->num == parsed_num);
 
     if (!workspace) {
-        y(map_open);
-        ystr("success");
-        y(bool, false);
-        ystr("error");
-        // TODO: better error message
-        ystr("No such workspace");
-        y(map_close);
-        return;
+        workspace = workspace_get(which, NULL);
     }
 
     HANDLE_EMPTY_MATCH;