From daf0157fc0719314668afef53b2233854a889dd9 Mon Sep 17 00:00:00 2001 From: Simon Ruderich Date: Wed, 10 Mar 2010 16:53:41 +0100 Subject: [PATCH] screenrc: Use a variable to build up hardstatus/caption. This makes it much easier to understand. No functional changes. --- screenrc.in | 31 +++++++++++++++++++++---------- 1 file changed, 21 insertions(+), 10 deletions(-) diff --git a/screenrc.in b/screenrc.in index 7b74b11..d887b8e 100644 --- a/screenrc.in +++ b/screenrc.in @@ -27,18 +27,29 @@ attrcolor b ".I" # for window borders in split mode). sorendition = Bw +# Make sure the temporary variable we use is empty. Thanks to +# http://gist.github.com/133000 for the idea to use setenv and to TauPan in +# #screen on Freenode (2010-03-10 16:11) for reminding me of it and searching +# it again. +unsetenv s + # Always display the caption. -caption always "%{= Bw}%3n %t" -# %{= Bw} - white on light blue background, also reset all attributes -# (necessary so everything is displayed correctly) -# %3n - window number -# %t - window name +setenv s "$s%{= Bw}" # - white on light blue background, also reset all + # attributes (necessary so everything is displayed + # correctly) +setenv s "$s%3n" # - window number +setenv s "$s " # - space +setenv s "$s%t" # - window name +caption always "$s" +unsetenv s # Always display the status line with open windows and the hostname. -hardstatus alwayslastline "%w%=%l %H" -# %w - number and names of windows -# %= - right align the following text -# %l - load average -# %H - hostname +setenv s "$s%w" # - number and names of windows +setenv s "$s%=" # - right align the following text +setenv s "$s%l" # - load average +setenv s "$s " # - space +setenv s "$s%H" # - hostname +hardstatus alwayslastline "$s" +unsetenv s # BINDINGS -- 2.45.2