diff options
author | Nicholas Marriott <nicm@cvs.openbsd.org> | 2015-07-13 15:37:27 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@cvs.openbsd.org> | 2015-07-13 15:37:27 +0000 |
commit | c1bacbefc9db845116d552124fdda8aa2dc85bdb (patch) | |
tree | 39af8d2eea2fcf1871960756962e1f9e051bdee7 /usr.bin/tmux | |
parent | d35c8e742abac47be8a58e904d12429edff33e0c (diff) |
Add a format to show if client is a control client. From Bruno Sutic.
Diffstat (limited to 'usr.bin/tmux')
-rw-r--r-- | usr.bin/tmux/format.c | 4 | ||||
-rw-r--r-- | usr.bin/tmux/tmux.1 | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/usr.bin/tmux/format.c b/usr.bin/tmux/format.c index 3daf2bfa6bb..2a1f8fa4277 100644 --- a/usr.bin/tmux/format.c +++ b/usr.bin/tmux/format.c @@ -1,4 +1,4 @@ -/* $OpenBSD: format.c,v 1.74 2015/06/18 23:55:24 nicm Exp $ */ +/* $OpenBSD: format.c,v 1.75 2015/07/13 15:37:26 nicm Exp $ */ /* * Copyright (c) 2011 Nicholas Marriott <nicm@users.sourceforge.net> @@ -711,6 +711,8 @@ format_defaults_client(struct format_tree *ft, struct client *c) format_add(ft, "client_tty", "%s", c->tty.path); if (c->tty.termname != NULL) format_add(ft, "client_termname", "%s", c->tty.termname); + format_add(ft, "client_control_mode", "%d", + !!(c->flags & CLIENT_CONTROL)); t = c->creation_time.tv_sec; format_add(ft, "client_created", "%lld", (long long) t); diff --git a/usr.bin/tmux/tmux.1 b/usr.bin/tmux/tmux.1 index 2d5502d1148..c8daa22df80 100644 --- a/usr.bin/tmux/tmux.1 +++ b/usr.bin/tmux/tmux.1 @@ -1,4 +1,4 @@ -.\" $OpenBSD: tmux.1,v 1.442 2015/07/13 13:36:29 nicm Exp $ +.\" $OpenBSD: tmux.1,v 1.443 2015/07/13 15:37:26 nicm Exp $ .\" .\" Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net> .\" @@ -3358,6 +3358,7 @@ The following variables are available, where appropriate: .It Li "client_activity_string" Ta "" Ta "String time client last had activity" .It Li "client_created" Ta "" Ta "Integer time client created" .It Li "client_created_string" Ta "" Ta "String time client created" +.It Li "client_control_mode" Ta "" Ta "1 if client is in control mode" .It Li "client_height" Ta "" Ta "Height of client" .It Li "client_last_session" Ta "" Ta "Name of the client's last session" .It Li "client_pid" Ta "" Ta "PID of client process" |