summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2012-12-20 19:30:57 +0100
committerSebastien Helleu <flashcode@flashtux.org>2012-12-20 19:30:57 +0100
commit135c740f739a8454c5450340302f802945520822 (patch)
tree317e85b12a42889f4ceef6b42b22ea48c13b4cbc
parent85eb3424cd376417cf738d789874ef2d233efaa6 (diff)
downloadweechat-135c740f739a8454c5450340302f802945520822.zip
core: improve completion of commands /help, /mute and /set
-rw-r--r--src/core/wee-command.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/src/core/wee-command.c b/src/core/wee-command.c
index 444f54eef..fca23fccb 100644
--- a/src/core/wee-command.c
+++ b/src/core/wee-command.c
@@ -6119,8 +6119,9 @@ command_init ()
" plugin: list commands for this plugin\n"
" command: a command name\n"
" option: an option name (use /set to see list)"),
- "-list|-listfull|%(commands)|%(config_options) "
- "%(plugins_names)|" PLUGIN_CORE "|%*",
+ "-list %(plugins_names)|" PLUGIN_CORE "|%*"
+ " || -listfull %(plugins_names)|" PLUGIN_CORE "|%*"
+ " || %(commands)|%(config_options)",
&command_help, NULL);
hook_command (NULL, "history",
N_("show buffer command history"),
@@ -6349,7 +6350,10 @@ command_init ()
" /mute -current msg * hi!\n"
" message to #weechat channel:\n"
" /mute -buffer irc.freenode.#weechat msg #weechat hi!"),
- "-current|-buffer|-all|%(commands) %(commands)|%*",
+ "-current %(commands)|%*"
+ " || -buffer %(buffers_plugins_names) %(commands)|%*"
+ " || -all %(commands)|%*"
+ " || %(commands)|%*",
&command_mute, NULL);
hook_command (NULL, "plugin",
N_("list/load/unload plugins"),
@@ -6479,7 +6483,8 @@ command_init ()
" /set diff\n"
" display changed options in irc plugin:\n"
" /set diff irc.*"),
- "%(config_options) %(config_option_values)",
+ "%(config_options) %(config_option_values)"
+ " || diff %(config_options)|%*",
&command_set, NULL);
hook_command (NULL, "unset",
N_("unset/reset config options"),