-
Notifications
You must be signed in to change notification settings - Fork 0
/
keybindings.el
47 lines (38 loc) · 1.61 KB
/
keybindings.el
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
;; Key bindings
;; Misc
(global-set-key [(control shift c)] 'comment-or-uncomment-region)
(global-set-key "\M-g" 'goto-line)
(global-unset-key "\C-z") ;C-z original desativado
(global-set-key "\C-x\C-z" 'eshell)
(global-set-key [(meta control up)] 'enlarge-window)
(global-set-key [(meta control down)] 'shrink-window)
(global-set-key [(meta shift right)] 'enlarge-window-horizontally)
(global-set-key [(meta shift left)] 'shrink-window-horizontally)
;; Grep dired
(global-set-key [(meta shift f)] 'rgrep)
(eval-after-load 'rgrep
'(progn
(add-to-list 'grep-find-ignored-directories "dist")
(add-to-list 'grep-find-ignored-directories "node_modules")
(add-to-list 'grep-find-ignored-directories ".serverless")
))
;; Window
(global-set-key [(shift up)] 'windmove-up)
(global-set-key [(shift left)] 'windmove-left)
(global-set-key [(shift right)] 'windmove-right)
(global-set-key [(shift down)] 'windmove-down)
(global-set-key (kbd "C-n")
(lambda () (interactive) (next-line 5)))
(global-set-key (kbd "C-p")
(lambda () (interactive) (previous-line 5)))
(global-set-key "\M-p" (lambda () (interactive)
(previous-line 4)
(scroll-down 4)) )
(global-set-key "\M-n" (lambda () (interactive)
(next-line 4)
(scroll-up 4)) )
(global-set-key [(control meta a)] 'smerge-keep-all)
(global-set-key [(control meta n)] 'smerge-next)
(global-set-key [(control meta p)] 'smerge-prev)
(global-set-key [(control meta u)] 'smerge-keep-upper)
(global-set-key [(control meta o)] 'smerge-keep-lower)