summaryrefslogtreecommitdiff
path: root/command.c
diff options
context:
space:
mode:
Diffstat (limited to 'command.c')
-rw-r--r--command.c24
1 files changed, 16 insertions, 8 deletions
diff --git a/command.c b/command.c
index c457e43..de1ec97 100644
--- a/command.c
+++ b/command.c
@@ -36,20 +36,28 @@ command_lookup(struct command *cmd, int ncmds, const char *binding) {
return NULL;
}
-static struct command emacs_commands[] = {
- { .bind = "d", .name = "emacs-dev", .nchildren = 0, .children = NULL },
+/* static struct command emacs_commands[] = { */
+/* { .bind = "d", .name = "emacs-dev", .nchildren = 0, .children = NULL }, */
+/* }; */
+
+static struct command browser_commands[] = {
+ { .bind = "s", .name = "chrome", .nchildren = 0, .children = NULL },
+ { .bind = "c", .name = "chromium", .nchildren = 0, .children = NULL },
+ { .bind = "f", .name = "firefox", .nchildren = 0, .children = NULL },
};
static const struct command examples[] = {
- { .bind = "f", .name = "firefox", .nchildren = 0, .children = NULL },
+ { .bind = "b",
+ .name = "browsers",
+ .nchildren = LENGTH(browser_commands),
+ .children = browser_commands
+ },
{ .bind = "e",
- .name = "emacs",
- .children = emacs_commands,
- .nchildren = LENGTH(emacs_commands)
+ .name = "emacs-dev",
+ .children = NULL,
+ .nchildren = 0
},
-
- { .bind = "N", .name = "networking", .nchildren = 0, .children = NULL },
};
struct command *