summaryrefslogtreecommitdiffstats
path: root/tmux.1
diff options
context:
space:
mode:
authornicm <nicm>2017-01-09 21:03:25 +0000
committernicm <nicm>2017-01-09 21:03:25 +0000
commit844f2eacf46842e18689f3b3ef464f67ea81dc61 (patch)
tree475fa75709aa14335dfe4c63a6eb0d6635053e46 /tmux.1
parent561b5c6fdbdafae52ac5b4bd963f0d75af344c5b (diff)
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 'tmux.1')
-rw-r--r--tmux.115
1 files changed, 15 insertions, 0 deletions
diff --git a/tmux.1 b/tmux.1
index a5be4617..04eb9de9 100644
--- a/tmux.1
+++ b/tmux.1
@@ -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 = ,