~ jonty
/.screenrc
Use Ctrl-F as command key.
Memorable key commands to split windows, switch windows, monitor.
Nice status line at bottom to list windows, highlight active window, and show current date/time.
Client applications see TERM=screen rather than TERM=linux which works better with some terminfo packages.
# .screenrc - Jonty's setup for screen
# 15-Apr-2004
# Use Ctrl-F as the command character
# Use Ctrl-F-Z as a replacement for Ctrl-F
escape ^fz
# This is how one can set a reattach password:
# password ODSJQf.4IJN7E # "1234"
# Give me an annoying audible bell, please
vbell on
# If terminal hangs up abruptly detach and keep screen running
# in the background
autodetach on
# Don't display the copyright page
startup_message off
# Emulate .logout message
pow_detach_msg "Screen session of \$LOGNAME \$:cr:\$:nl:ended."
# advertise hardstatus support to $TERMCAP
# termcapinfo * '' 'hs:ts=\E_:fs=\E\\:ds=\E_\E\\'
# make the shell in every window a login shell
#shell -$SHELL
# autoaka testing
# shellaka '> |tcsh'
# shellaka '$ |sh'
# set every new windows hardstatus line to something descriptive
# defhstatus "screen: ^En (^Et)"
# Set scrollback buffer for each screen to 1000 lines (default
# is 100)
defscrollback 1000
# don't kill window after a process dies
# zombie "^["
################
#
# keybindings
#
# Remove some stupid / dangerous key bindings
bind .
bind ^\
bind \\
bind ^h
bind h
#make them better
bind I login on
bind O login off
bind } history
# Jon's preferences
# Split screen controls
bind s split
bind o focus
bind x remove
bind m monitor
bind "^[[c" next
bind "^[Oc" next
bind "^[[1;5C" next
bind "^[[d" prev
bind "^[Od" prev
bind "^[[1;5D" prev
# Hack to automatically set autoindent mode when pasting into vi
# Prepend/append register [/] to the paste if ^t^] is pressed.
##register [ "\033:se noai\015a" ##register ] "\033:se ai\015a" ##bind
^] paste [.]
################
#
# Status lines
#
# Caption shows the active windows, date, time on last line of display
#caption always "%{.bw}%-w%{.rw}%n %t%{-}%+w %=%{..y}%D %d-%M %c "
caption always "%{.bw}%-w%{.rw}%n %t%{-}%+w %-18=%{..y}%D %d-%M %c"
# Hardstatus line shows as title bar in putty, so use host name
defhstatus "^EH"
# hardstatus alwaysignore
# hardstatus alwayslastline "%w"
################
#
# default windows
#
screen -t su 0 su - root
screen -t wyrd 5 wyrd
screen -t web 4 links http://wiki
screen -t rss 3 snownews
screen -t mail 2 mutt
screen -t sh 1
################
#
# Terminal seen by applications
#
#term linux
term screen
################
#
# xterm tweaks
#
#xterm understands both im/ic and doesn't have a status line.
#Note: Do not specify im and ic in the real termcap/info file as
#some programs (e.g. vi) will not work anymore.
#termcap xterm hs@:cs=\E[%i%d;%dr:im=\E[4h:ei=\E[4l
#terminfo xterm hs@:cs=\E[%i%p1%d;%p2%dr:im=\E[4h:ei=\E[4l
#80/132 column switching must be enabled for ^AW to work
#change init sequence to not switch width
#termcapinfo xterm Z0=\E[?3h:Z1=\E[?3l:is=\E[r\E[m\E[2J\E[H\E[?7h\E[?1;4;6l
# Make the output buffer large for (fast) xterms.
#termcapinfo xterm* OL=10000
# tell screen that xterm can switch to dark background and has function
# keys.
#termcapinfo xterm 'VR=\E[?5h:VN=\E[?5l'
#termcapinfo xterm 'k1=\E[11~:k2=\E[12~:k3=\E[13~:k4=\E[14~'
#termcapinfo xterm 'kh=\E[1~:kI=\E[2~:kD=\E[3~:kH=\E[4~:kP=\E[H:kN=\E[6~'
# special xterm hardstatus: use the window title.
#termcapinfo xterm 'hs:ts=\E]2;:fs=\007:ds=\E]2;screen\007'
#terminfo xterm 'vb=\E[?5h$<200/>\E[?5l'
#termcapinfo xterm 'vi=\E[?25l:ve=\E[34h\E[?25h:vs=\E[34l'
# emulate part of the 'K' charset
#termcapinfo xterm 'XC=K%,%\E(B,[\304,\\\\\326,]\334,{\344,|\366,}\374,~\337'
# xterm-52 tweaks:
# - uses background color for delete operations
#termcapinfo xterm ut