From 94f86edfee9480b0e35af8adc2e4371b3caa3bca Mon Sep 17 00:00:00 2001 From: Nicholas Marriott Date: Sun, 3 Jul 2011 18:18:15 +0000 Subject: Include the existing window and session name in the prompt when renaming and add a new key binding ($) for rename session. From Tiago Cunha. --- cmd-command-prompt.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'cmd-command-prompt.c') diff --git a/cmd-command-prompt.c b/cmd-command-prompt.c index 48a11916..f0f1d12d 100644 --- a/cmd-command-prompt.c +++ b/cmd-command-prompt.c @@ -59,8 +59,13 @@ void cmd_command_prompt_key_binding(struct cmd *self, int key) { switch (key) { + case '$': + self->args = args_create(1, "rename-session '%%'"); + args_set(self->args, 'I', "#S"); + break; case ',': self->args = args_create(1, "rename-window '%%'"); + args_set(self->args, 'I', "#W"); break; case '.': self->args = args_create(1, "move-window -t '%%'"); -- cgit