-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.inputrc
More file actions
55 lines (44 loc) · 1.79 KB
/
.inputrc
File metadata and controls
55 lines (44 loc) · 1.79 KB
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
# do not bell on tab-completion set bell-style none
set bell-style none
set meta-flag on
set input-meta on
set convert-meta off
set output-meta on
set show-all-if-ambiguous on
set completion-ignore-case on
# only complete with comands begining with already typed
"\e[A":history-search-backward
"\e[B":history-search-forward
# show mode
set show-mode-in-prompt on
###########################################################
# Use Vi, not Emacs, style editing
set editing-mode vi
# Show all completions as soon as I press tab, even if there's more than one
set show-all-if-ambiguous on
# Ignore case
set completion-ignore-case on
###########################################################
# Keymaps for when we're in command mode (e.g., after hitting ESC)
set keymap vi-command
# Insert the arguments from the last command
"p": "i !!*\r"
# When hitting option-up/option-down, cycle through the previous commands
# which start with the prefix you've entered, rather than just cycling through
# the last entered commands.
# In OS X's Terminal.app preferences, I have 'Use option as meta key' off, and
# have mapped "option cursor up" to "\033\033[A" and "option cursor down" to
# "\033\033[B".
# Feel free to bind to whatever you want. Delete the first '\e' in the keymap
# to set plain up/down to do a history search by default.
"\e[A": history-search-backward
"\e[B": history-search-forward
###########################################################
# Keymaps for when we're in insert (i.e., typing stuff in) mode
set keymap vi-insert
# Option-up/option-down should also apply to insert mode
"\e[A": history-search-backward
"\e[B": history-search-forward
# Needed because binding 'p' in command mode above wipes its insert mode
# function, too. This fixes that, and will insert 'p' when you type 'p'.
"p": self-insert