mirror of
https://github.com/tmate-io/tmate-ssh-server.git
synced 2020-11-18 19:53:51 -08:00
Sync OpenBSD patchset 928:
Include the existing window and session name in the prompt when renaming and add a new key binding ($) for rename session. From Tiago Cunha.
This commit is contained in:
parent
e097f0b4ee
commit
fce026eb32
@ -59,8 +59,13 @@ void
|
|||||||
cmd_command_prompt_key_binding(struct cmd *self, int key)
|
cmd_command_prompt_key_binding(struct cmd *self, int key)
|
||||||
{
|
{
|
||||||
switch (key) {
|
switch (key) {
|
||||||
|
case '$':
|
||||||
|
self->args = args_create(1, "rename-session '%%'");
|
||||||
|
args_set(self->args, 'I', "#S");
|
||||||
|
break;
|
||||||
case ',':
|
case ',':
|
||||||
self->args = args_create(1, "rename-window '%%'");
|
self->args = args_create(1, "rename-window '%%'");
|
||||||
|
args_set(self->args, 'I', "#W");
|
||||||
break;
|
break;
|
||||||
case '.':
|
case '.':
|
||||||
self->args = args_create(1, "move-window -t '%%'");
|
self->args = args_create(1, "move-window -t '%%'");
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* $Id: key-bindings.c,v 1.98 2011-01-07 14:45:34 tcunha Exp $ */
|
/* $Id$ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
|
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
|
||||||
@ -106,6 +106,7 @@ key_bindings_init(void)
|
|||||||
{ '!', 0, &cmd_break_pane_entry },
|
{ '!', 0, &cmd_break_pane_entry },
|
||||||
{ '"', 0, &cmd_split_window_entry },
|
{ '"', 0, &cmd_split_window_entry },
|
||||||
{ '#', 0, &cmd_list_buffers_entry },
|
{ '#', 0, &cmd_list_buffers_entry },
|
||||||
|
{ '$', 0, &cmd_command_prompt_entry },
|
||||||
{ '%', 0, &cmd_split_window_entry },
|
{ '%', 0, &cmd_split_window_entry },
|
||||||
{ '&', 0, &cmd_confirm_before_entry },
|
{ '&', 0, &cmd_confirm_before_entry },
|
||||||
{ '(', 0, &cmd_switch_client_entry },
|
{ '(', 0, &cmd_switch_client_entry },
|
||||||
|
4
tmux.1
4
tmux.1
@ -14,7 +14,7 @@
|
|||||||
.\" IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
|
.\" IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
|
||||||
.\" OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
.\" OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
.\"
|
.\"
|
||||||
.Dd $Mdocdate: July 2 2011 $
|
.Dd $Mdocdate: July 3 2011 $
|
||||||
.Dt TMUX 1
|
.Dt TMUX 1
|
||||||
.Os
|
.Os
|
||||||
.Sh NAME
|
.Sh NAME
|
||||||
@ -237,6 +237,8 @@ Break the current pane out of the window.
|
|||||||
Split the current pane into two, top and bottom.
|
Split the current pane into two, top and bottom.
|
||||||
.It #
|
.It #
|
||||||
List all paste buffers.
|
List all paste buffers.
|
||||||
|
.It $
|
||||||
|
Rename the current session.
|
||||||
.It %
|
.It %
|
||||||
Split the current pane into two, left and right.
|
Split the current pane into two, left and right.
|
||||||
.It &
|
.It &
|
||||||
|
Loading…
x
Reference in New Issue
Block a user