-
Notifications
You must be signed in to change notification settings - Fork 21
/
screenrc
92 lines (75 loc) · 3.73 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
# ------------------------------------------------------------------------------
# FILE: .screenrc
# DESCRIPTION: Screen configuration file.
# AUTHOR: Sorin Ionescu <[email protected]>
# VERSION: 1.0.1
# ------------------------------------------------------------------------------
# ------------------------------------------------------------------------------
# General Options
# ------------------------------------------------------------------------------
escape ^\\ # Set the escape sequence to CTRL+\.
defutf8 on # Make UTF-8 encoding default.
altscreen on # Use alternate screen to clean exit out of vim.
autodetach on # Detach on hang-up.
defscrollback 10000 # Makes the default scroll back large.
msgwait 2 # Display a message for 2 seconds.
nonblock on # Do not block when a program freezes.
startup_message off # Do not display the copyright page.
# Copy to Mac OS X clipboard.
bind > eval "writebuf" "exec sh -c 'pbcopy < /tmp/screen-exchange'"
# ------------------------------------------------------------------------------
# Bell
# ------------------------------------------------------------------------------
activity "Active: %n (%t) [%w:%s]"
bell "Bell: %n (%t) [%w:%s]^G"
vbell on
vbell_msg "[[[ DING ]]]"
# ------------------------------------------------------------------------------
# Key Bindings
# ------------------------------------------------------------------------------
# Disable stupid/dangerous key bindings.
bind k
bind W
bind ^k
bind .
bind ^\
bind \\
bind ^h
bind h
bind 'K' kill
bind 'W' windowlist
bind j focus down # Switch to down split.
bind k focus up # Switch to up split.
bindkey -k k1 prev # F1 = Cycle through windows backwards.
bindkey -k k2 next # F2 = Cycle through windows forwards.
bindkey -k k3 resize +1 # F3 = Increase the current split window size by 1 line.
bindkey -k k4 resize -1 # F4 = Decrease the current split window size by 1 line.
bindkey -k k5 focus # F5 = Focus.
bindkey -k k6 split # F6 = Split horizontally.
bindkey -k k7 remove # F7 = Remove split.
bindkey -k k8 hardstatus alwayslastline # F8 = Turn off status bar.
bindkey -k k9 hardstatus alwaysignore # F9 = Turn on status bar.
# ------------------------------------------------------------------------------
# Status Line
# ------------------------------------------------------------------------------
hardstatus alwayslastline "%{=b W}%{k} %= %w %="
# ------------------------------------------------------------------------------
# Terminal Settings
# ------------------------------------------------------------------------------
attrcolor b ".I" # Allow bold colours - necessary for some reason.
defbce on # Erase characters with the current background colour.
#termcapinfo xterm* ti@:te@ # Scrolling.
termcapinfo xterm-256color "Co#256:AB=\E[48;5;%dm:AF=\E[38;5;%dm" # Colours.
term screen-256color-bce # Terminal.
# ------------------------------------------------------------------------------
# Windowing Settings
# ------------------------------------------------------------------------------
# Start window numbering at 1, not 0.
bind c screen 1
bind 0 select 10
# ------------------------------------------------------------------------------
# Program Launch
# ------------------------------------------------------------------------------
screen -t sh 1 -$SHELL
# Double-check to force the focus to 1 after launch.
select 1