Home » Questions » Computers [ Ask a new question ]

Changing Emacs bindings in Mac OS X

Changing Emacs bindings in Mac OS X

I'm trying to reset the binding for "C-x C-c". Specifically, I want to rebind it to a function that asks me if I really want to quit (I just fat finger it way too much). I've done this before under Linux with no issues. Under Mac OS X, when I evaluate the expression

Asked by: Guest | Views: 254
Total answers/comments: 2
Guest [Entry]

"Somehow, you are using smartquotes.

Use

(global-unset-key ""\C-x\C-c"") ;; use this

instead of

(global-unset-key “\C-x\C-c”) ;; Not this one!"
Guest [Entry]

"This is a start, here is a somewhat relevant page http://www.delorie.com/gnu/docs/emacs/emacs_496.html , but it seems what you want is to redefine the binding, not to remove it. Or just always have a modified file around, that way it will ask before quitting (and you could automate that in your .emacs or ~/.emacs.d/init.el )

http://www.delorie.com/gnu/docs/emacs/emacs_502.html"