about summary refs log tree commit diff stats
path: root/src/plugins/api.c
diff options
context:
space:
mode:
authorJames Booth <boothj5@gmail.com>2016-07-05 22:10:41 +0100
committerJames Booth <boothj5@gmail.com>2016-07-05 22:10:41 +0100
commit97f79970252a06a1583ca1e1c8b22111720ddf94 (patch)
treedbcfe2391c73fc5b12a1eabd710d82a1aad892d4 /src/plugins/api.c
parent99598e7d57be923ce18fa5cded11431e5b462720 (diff)
downloadprofani-tty-97f79970252a06a1583ca1e1c8b22111720ddf94.tar.gz
Move adding plugins commands to autocompleters
Diffstat (limited to 'src/plugins/api.c')
-rw-r--r--src/plugins/api.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/plugins/api.c b/src/plugins/api.c
index c8e6a166..e98e44d5 100644
--- a/src/plugins/api.c
+++ b/src/plugins/api.c
@@ -52,6 +52,7 @@
 #include "command/cmd_defs.h"
 #include "window_list.h"
 #include "common.h"
+#include "command/cmd_ac.h"
 
 void
 api_cons_alert(void)
@@ -144,6 +145,9 @@ api_register_command(const char *const plugin_name, const char *command_name, in
     command->help = help;
 
     callbacks_add_command(plugin_name, command);
+
+    cmd_ac_add(command->command_name);
+    cmd_ac_add_help(&command->command_name[1]);
 }
 
 void