-
Notifications
You must be signed in to change notification settings - Fork 5
/
rc-hotkeys.el
35 lines (28 loc) · 1.12 KB
/
rc-hotkeys.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
;; mac hotkeys
(global-set-key (kbd "<s-left>") 'beginning-of-line)
(global-set-key (kbd "<s-right>") 'end-of-line)
(global-set-key (kbd "<s-up>") 'beginning-of-buffer)
(global-set-key (kbd "<s-down>") 'end-of-buffer)
(global-set-key (kbd "<M-up>") 'backward-paragraph)
(global-set-key (kbd "<M-down>") 'forward-paragraph)
(global-set-key (kbd "s-o") 'find-file)
(global-set-key (kbd "s-w") 'kill-this-buffer)
(global-set-key (kbd "<s-return>") 'open-next-line)
(global-set-key (kbd "<M-backspace>") 'my-backward-delete-word)
;; linux hotkeys
(global-set-key (kbd "C-z") 'undo)
(global-set-key (kbd "C-S-x") 'clipboard-kill-region)
(global-set-key (kbd "C-S-c") 'clipboard-kill-ring-save)
(global-set-key (kbd "C-S-v") 'x-clipboard-yank)
;; comment or uncomment region
(global-set-key (kbd "C-c /") 'comment-or-uncomment-region)
;; ido-imenu
(global-set-key (kbd "C-x C-i") 'ido-imenu)
;; buffer-menu
(global-set-key (kbd "C-x C-b") 'ibuffer)
;; kill current buffer
(global-set-key (kbd "C-x k") 'kill-this-buffer)
;; find recent files
(global-set-key (kbd "C-x f") 'recentf-ido-find-file)
;; git
(global-set-key (kbd "C-c g") 'magit-status)