Alex Rivera | Logout

What are your favorite global key bindings in emacs ?

Asked 2010-06-26T17:36:21.630
25

Mine are:

(global-set-key [f6] 'compile-buffer)
(global-set-key [f7] 'kmacro-start-macro-or-insert-counter)
(global-set-key [f8] 'kmacro-end-and-call-macro)
(global-set-key [f9] 'call-last-kbd-macro)
(global-set-key [f10] 'name-and-insert-last-kbd-macro)
(global-set-key [f12] 'menu-bar-open)  ; originally bound to F10
(global-set-key "\C-cR" 'rename-current-file-or-buffer)
(global-set-key "\C-cD" 'Delete-current-file-or-buffer)

The name-and-insert-last-keyboard-macro is from another Stack Overflow question.

Edit
Report

2 Answers

4
(bind "C-t" (lookup-key global-map (kbd "C-x")))

I never transpose characters so I rebound it to mean C-x when used as a prefix key. I just can't stand reaching all the way for the "x" key on Dvorak.

I'm also using this macro since today:

(defmacro bind (key fn)
  `(global-set-key (kbd ,key) ,(if (listp fn) fn `',fn)))
answered 2010-06-27T03:30:05.700
3

Breadcrumb:

(require 'breadcrumb)
(global-set-key [(control f2)]          'bc-set)
(global-set-key [(f2)]                  'bc-previous)
(global-set-key [(shift f2)]            'bc-next)
(global-set-key [(meta f2)]             'bc-list)
answered 2010-07-16T02:39:28.690

Your Answer