-
Notifications
You must be signed in to change notification settings - Fork 107
/
Copy pathdot.inputrc
70 lines (59 loc) · 2.33 KB
/
dot.inputrc
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
# Use vi editing mode
#set editing-mode vi
#set keymap vi
# Set visible bell
set bell-style visible # Options: none, visible, audible
set keyseq-timeout 0 # The duration Readline will wait for a character
# Adds punctuation as word delimiters
set bind-tty-special-chars off
# Completion Options
set page-completions on # Page completions more like.
set completion-ignore-case on # Ignore case
set completion-query-items 200 # Show double the number of default completions.
set match-hidden-files off # Don't match hidden files
set show-all-if-ambiguous on # Enable single tab completion
set show-all-if-unmodified on # List immediately, don't bell if ambigous.
set visible-stats on # Show item type like 'ls -F', displays /,*,@ next to name
set colored-stats on
# Fix for accents input with UTF-8.
set meta-flag on
set input-meta on
set output-meta on
set convert-meta off
$if mode=emacs
# Readline specific functions
"\e[1~": beginning-of-line # CTRL + A
"\e[4~": end-of-line # CTRL + E
"\e[5C": forward-word # Control + Right
"\e[5D": backward-word # Control + Left
"\e[3~": delete-char # Delete
"\e[2~": quoted-insert # CTRL + v
"\e[5~": history-search-backward # Page Up
"\e[6~": history-search-forward # Page Down
#"\t": menu-complete # Tab cycles through completions
# Mappings for Alt/Ctrl left-arrow and right-arrow word moving
# Alt-arrow
"\e[1;3D": backward-word
"\e[1;3C": forward-word
# Ctrl-arrow
"\e[1;5C": forward-word
"\e[1;5D": backward-word
# If the above prevents Left and Right from working, try this:
#"\e[C": forward-char # Move forward one character.
#"\e[D": backward-char # Move backwards one character.
$endif
# Avoid binding ^J, ^M, ^C, ^?, ^S, ^Q, etc.
$if mode=vi
set keymap vi-command
"gg": beginning-of-history
"G": end-of-history
"k": history-search-backward
"j": history-search-forward
"?": reverse-search-history
"/": forward-search-history
set keymap vi-insert
"\C-l": clear-screen
"\C-w": backward-kill-word
"\C-a": beginning-of-line
"\C-e": end-of-line
$endif