-
Notifications
You must be signed in to change notification settings - Fork 0
/
.screenrc
74 lines (56 loc) · 2.25 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
# File: ~/.screenrc from the following sources
# https://github.com/dr-costas/myscreen_files
# https://gist.github.com/ErDmKo/10242225
# https://www.howtogeek.com/devops/define-a-great-gnu-screen-profile-using-screenrc/
# Deactivate the startup message of screen
startup_message off
# Vim like key bindings for moving around windows
bind l focus right # C-a l goes right
bind h focus left # C-a h goes left
bind k focus up # C-a k goes up
bind j focus down # C-a j goes down
# Bind keys for resizing
bind L resize -h +10 # C-a L increases horizontally by 10
bind H resize -h -10 # C-a H decreases horizontally by 10
bind K resize -v +10 # C-a K increases vertically by 10
bind J resize -v -10 # C-a K decreases vertically by 10
# Setup hardstatus
hardstatus off
hardstatus alwayslastline
#hardstatus string '%{= .g} %H |%=%{K}%{= w}%?%{K}%-Lw%?%{r}(%{W}%{w}%n%{w}*%f%t%?(%u)%?%{r})%{w}%?%{K}%+Lw%?%= %{g}|%{B} %m-%d %{W}%c %{g} '
hardstatus string "%{gk}[ $USER@%{G}%H %{g}][%= %{wk}%?%-Lw%?%{=b kR}(%{W}%n*%f %t%?(%u)%?%{=b kR})%{= kw}%?%+Lw%?%?%= %{g}][%{Y}%l%{g}]%{=b C}[ %d/%m/%Y %c:%s%{-} ]%{W}"
# Fix for residual editor text
altscreen on
# Fix for Name column in windowlist only show "bash"
windowlist string "%4n %h%=%f"
# Indicate 256 color screen
term screen-256color
# Bind Ctrl+A f or F for activating/deactivating hardstatus line
bind f eval "hardstatus ignore"
bind F eval "hardstatus alwayslastline"
defscrollback 10000
# detach on hangup
autodetach on
# emulate .logout message
pow_detach_msg "Screen session of \$LOGNAME \$:cr:\$:nl:ended."
# Termcapinfo for xterm
termcapinfo xterm* Z0=E[?3h:Z1=E[?3l:is=E[rE[mE[2JE[HE[?7hE[?1;4;6l # Do not resize window
termcapinfo xterm* OL=1000
# 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=\EOH:kI=\E[2~:kD=\E[3~:kH=\EOF:kP=\E[5~:kN=\E[6~'
# Remove various keyboard bindings
bind x # Do not lock screen
bind ^x # Idem
bind h # Do not write out copy of screen to disk
bind ^h # Idem
bind ^ # Do not kill all windows/exit screen
bind . # Disable dumptermcap
# Add keyboard bindings
bind } history
bind k kill
# Set shell
shell /usr/bin/bash
# EOF