forked from startup-class/dotfiles
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.screenrc
130 lines (120 loc) · 5.5 KB
/
.screenrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
# GNU Screen configuration file
# Balaji S. Srinivasan <[email protected]>
#
# Notes
# -----
# 1. Modified to work with Emacs: C-t is the action command, not C-a.
# 2. To change the colors of the hardstatus line, change this line:
# sorendition "+b +kG"
# Example: blue (+b) highlight with black text (k) on a green background (G)
# Example: sorendition "+r +kG" is red highlighting with black text on a green background
#
# Modification of original files by Sven Guckes, Sarunas Vancevicius, and Mike Perry
# Sarunas Vancevicius original: http://www.redbrick.dcu.ie/~svan/configs/screenrc
# Mike Perry original: http://fscked.org/writings/225notes/unix/.screenrc
## -----------------------------------------------------------------------------------------
## -- 1) Set variables and keybindings for emacs compatibility (remapping Ctrl-A to Ctrl-T)
## -----------------------------------------------------------------------------------------
markkeys "h=^B:l=^F:$=^E" # emacs style keybindings during copy mode movement in screen
autodetach on # default: on
crlf off # default: off
#deflogin off # default: on
hardcopy_append on # default: off
startup_message off # default: on
vbell off # default: ???
escape "^Tt" # ctrl-A default interferes with emacs keybindings for terminal
defutf8 on # unicode by default
defscrollback 10000 # default: 100
silencewait 15 # default: 30
activity "activity in %n (%t) [%w:%s]~"
bell "bell in %n (%t) [%w:%s]~"
# Change keybindings for convenience
bind ^Q mapdefault
bind q mapdefault
bind k
bind ^k
bind .
bind ^\
bind \\
bind ^h
bind h
bind ''
bind 'L'
#bind 'I' login on
#bind 'O' login off
bind '}' history
bind ^a
# aterm bindings
bindkey "Oc" next
bindkey "Od" prev
# Emacs compatibility
# Easy switching of windows without p/n confusion, as ctrl-p and ctrl-n
# are frequently used in emacs but u/j are not...
bind 'u' prev
bind ^U prev
bind 'j' next
bind ^J next
# Emacs compatibility for screen movement (if you use subscreen regions)
# Using tab to move around regions gets annoying. These help.
bind ^P focus up
bind 'p' focus up
bind ^N focus down
bind 'n' focus down
bind ^F focus top
bind 'f' focus top
bind ^B focus bottom
bind 'b' focus bottom
## -------------------------------------------------------------------------------------------------
## -- 2) Hardstatus line (aka navigation bar at bottom)
## and sorendition (aka color scheme for navigation bar)
## -------------------------------------------------------------------------------------------------
# 2.1) sorendition = color scheme
# Set the colors for the "messages" and "text marking"
# Example: "+b kG" = blue screen, black text, green background. Change
# to "+b kR" and so on to distinguish machines.
sorendition "+b kG"
# 2.2) hardstatus = navigation bar @ bottom
hardstatus alwayslastline "%H %-Lw%{= BW}%50>%n%f* %t%{-}%+Lw%<"
# 2.3) Autoload two screen tabs for emacs/bash.
screen -t emacs 0
screen -t bash 1
# 2.4) Description of the keywords used in hardstatus
# caption always "%?%F%{-b bc}%:%{-b bb}%?%C|%D|%M %d|%H%?%F%{+u wb}%? %L=%-Lw%45>%{+b by}%n%f* %t%{-}%+Lw%-0<"
#
# Anything I don't describe is treated literally.
#
# %? - Start of a conditional statement.
# %F - Use this part of the statement if the window has focus (i.e. it
# is the only window or the currently active one).
# %{-b bc} - Turn off bold, blue foreground, cyan background.
# %: - else
# %{-b bb} - Turn off bold, blue foreground, blue background (this obscures
# the text on non-focused windows and just gives a blue line).
# %? - End conditional statement.
# %C - time (hh:mm, leading space) in 12 hour format
# %D - Three-letter day-of-week appreviation
# %M - Three-letter month appreviation
# %d - Day of the month
# %H - hostname
# %? - Start of conditional statement.
# %F - Use this part of the statement if the window has focus.
# %{+u wb} - underlined, white foreground, blue background
# %? - End conditional (if not focused, text remaind blue on blue).
# %L= - truncation/padding point. With the 'L' qualifier, basically
# just acts as a reference point. Further truncation/padding is
# done relative to here, not the beginning of the string
# %-Lw - window list up to but not including the current window (-),
# show window flags (L)
# %45> - truncation/padding marker; place this point about 45% of the
# way into the display area (45)
# %{+b by} - add bold (still underlined from before), blue foreground,
# yellow background
# %n - number of the current window
# %f - flags for current window
# %t - title of current window
# %{-} - undo last color change (so now we're back to underlined white
# on blue) (technically, this is a pop; a second invocation
# would drop things back to unadorned blue on cyan)
# %+Lw - window list from the next window on (-), show window flags (L)
# %-0< - truncation/padding point. Place this point zero spaces (0)
# from the right margin (-).