-
-
Notifications
You must be signed in to change notification settings - Fork 5
/
.nanorc
38 lines (28 loc) · 957 Bytes
/
.nanorc
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
# ^G to display all bindings
# inspiration
# - https://github.com/davidhcefx/Modern-Nano-Keybindings
set linenumbers
set autoindent
set numbercolor yellow,normal
set afterends # `Ctrl+Right` move to word ends instead of word starts
set historylog # remember search history
set wordchars "_" # recognize '_' as part of a word
bind M-1 help all # fix ^G been used
# less-style page navigation bindings
bind ^G firstline all
bind M-G lastline all
# ^u & ^d to page up and down, like less
bind ^U pageup all
bind ^D pagedown all
# https://www.nano-editor.org/dist/latest/nanorc.5.html
bind ^w chopwordleft main
# rebind search
bind ^F whereis main
# add/remove comment shortcut
bind M-/ comment main
# opt left/right word jump mapping
bind M-B prevword main
bind M-F nextword main
set matchbrackets "(<[{)>]}"
# https://github.com/scopatz/nanorc/ is included after this line
include ~/.nano/*.nanorc