Skip to content

Instantly share code, notes, and snippets.

@leventis
Created December 19, 2019 18:48
Show Gist options
  • Save leventis/2868e13bc5e0de0f3c9dfb2e85feae5b to your computer and use it in GitHub Desktop.
Save leventis/2868e13bc5e0de0f3c9dfb2e85feae5b to your computer and use it in GitHub Desktop.
screen configuration file
# Allow bold colors - necessary for some reason
attrcolor b ".I"
# Tell screen how to set colors. AB = background, AF=foreground
termcapinfo xterm 'Co#256:AB=\E[48;5;%dm:AF=\E[38;5;%dm'
# Enables use of shift-PgUp and shift-PgDn
termcapinfo xterm|xterms|xs|rxvt ti@:te@
# Erase background with current bg color
defbce "on"
# Enable 256 color term
term xterm-256color
# Cache 10000 lines for scroll back
defscrollback 10000
# Show hardstatus
hardstatus alwayslastline
# Configure tabbed, colored hardstatus line
hardstatus string '%{= Kd} %{= Kd}%-w%{= Kr}[%{= KW}%n %t%{= Kr}]%{= Kd}%+w %-= %{KG} %H%{KW}|%{KY}%101`%{KW}|%D %M %d %Y%{= Kc} %C%A%{-}'
# Bind ctrl-a f to hide the hardstatus line
bind f eval "hardstatus ignore"
# Bind ctrl-a F to show the hardstatus line
bind F eval "hardstatus alwayslastline"
# Customize the logfile location and name
# See: https://www.gnu.org/software/screen/manual/screen.html#String-Escapes
logfile /tmp/screenlog_%Y%m%d_%H%M%S.txt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment