aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--wee_slack.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/wee_slack.py b/wee_slack.py
index 07c7526..a7ce6fe 100644
--- a/wee_slack.py
+++ b/wee_slack.py
@@ -4947,16 +4947,18 @@ def command_back(data, current_buffer, args):
@utf8_decode
def command_label(data, current_buffer, args):
"""
- /label <name>
+ /label <name>|-unset
Rename a channel or thread buffer. Note that this only changes the short
name and that it's not permanent. It will only last as long as you keep the
buffer and wee-slack open.
"""
channel = EVENTROUTER.weechat_controller.buffers[current_buffer]
- channel.label = args
+ channel.label = args if args != "-unset" else None
channel.rename()
return w.WEECHAT_RC_OK
+command_label.completion = "-unset %-"
+
@utf8_decode
def set_unread_cb(data, current_buffer, command):