summaryrefslogtreecommitdiffstats
path: root/usr.bin/tmux/tmux.1
diff options
context:
space:
mode:
authornicm <nicm@openbsd.org>2017-01-09 21:03:25 +0000
committernicm <nicm@openbsd.org>2017-01-09 21:03:25 +0000
commitb51cc70cc7a85f9017c7d04161a69aaa7ad2d355 (patch)
treeecb9941e5e4d6850ae9ec244874009d3bbe6902e /usr.bin/tmux/tmux.1
parentWhen a HT node leaves or reassociates as a non-HT node, (diff)
downloadwireguard-openbsd-b51cc70cc7a85f9017c7d04161a69aaa7ad2d355.tar.xz
wireguard-openbsd-b51cc70cc7a85f9017c7d04161a69aaa7ad2d355.zip
Add simple comparisons in formats: #{==:a,b} and #{!=:a,b} ("a" and "b"
are expanded so can compare formats). And expand the condition to #{?a,b,c} (the "a" part) if it doesn't work as a simple lookup. Also add FORMAT_NOJOBS flag to disable jobs in a format.
Diffstat (limited to 'usr.bin/tmux/tmux.1')
-rw-r--r--usr.bin/tmux/tmux.117
1 files changed, 16 insertions, 1 deletions
diff --git a/usr.bin/tmux/tmux.1 b/usr.bin/tmux/tmux.1
index 4b7b4b6d468..b319537efa4 100644
--- a/usr.bin/tmux/tmux.1
+++ b/usr.bin/tmux/tmux.1
@@ -1,4 +1,4 @@
-.\" $OpenBSD: tmux.1,v 1.519 2017/01/09 19:27:00 nicm Exp $
+.\" $OpenBSD: tmux.1,v 1.520 2017/01/09 21:03:25 nicm Exp $
.\"
.\" Copyright (c) 2007 Nicholas Marriott <nicholas.marriott@gmail.com>
.\"
@@ -3397,6 +3397,21 @@ is enabled, or
.Ql no
if not.
.Pp
+Simple comparisons may be expressed by prefixing two comma-separated
+alternatives by
+.Ql ==
+or
+.Ql !=
+and a colon.
+For example
+.Ql #{==,#{host},myhost}
+will be replaced by
+.Ql 1
+if running on
+.Ql myhost ,
+otherwise by
+.Ql 0.
+.Pp
A limit may be placed on the length of the resultant string by prefixing it
by an
.Ql = ,