Emacs Cheat Sheet General and File Commands C-x C-c Exit Emacs C-_ (C-g) Undo - you can also use C-x u (Cancel command) C-x C-f (C-x C-i) Open a file. (open file and paste in buffer) C-x C-s (C-x C-w) Save buffer to file (Save as). M-x revert-buffer Revert to the last saved version. M-x print-buffer Send buffer to the printer Search C-s (C-r) Search forward (backwards) M-% (M-x replace-string) Replace (Replace all) M-g g Go to line number Kill and Yank Commands C-SPACE (C-x C-x) Set mark (Swap mark and cursor) C-w (M-w) Kill region (copy) C-d (M-d) (C-k) Delete character (Kill Word) (Kill Line) C-y (M-y) Yank (cycle kill ring) Help Commands c-h ? (C-h m) (C-c ?) Help main menu (mode help) (current mode) C-h i (C-h a) (C-h b) Info Manuals (Command help) (key binding) C-M-v Scroll the help window Navigation Commands C-f (C-b) Forward (backward) one character M-f (M-b) Forward (backward) one word C-n (C-p) Next (previous) line C-a (C-e) Beginning (end) of line C-v (M-v) Page down (up) M-< (M-<) Beginning (end) of buffer C-l Redraw screen (centres on current line) Multiple Buffer Commands C-x k Close current buffer C-x b Switch to named buffer C-x 2 (C-x 5) Horizontal split (vertical) C-x 1 (C-x 0) Only show this buffer (Hide this buffer) Rectangle Commands C-x r k (C-x r y) Kill rectangle (Yank rectangle) C-x r d (C-x r c) Delete rectangle (clear) C-x r t (C-x r o) replace rectangle with string (space) Formatting and Python Mode M-/ auto-complete M-q (C-M-\) format text to paragraphs (reindent code) C-c C-c (C-c C-w Executes the current Python buffer (Runs pychecker). C-c ! (M-x shell) Brings up the Python Shell (bash shell). C-g means CTRL and the g key. M-x means ALT and the x key. If you do not have an ALT key then use ESC then key. Do not type the brackets. Get the latest copy from http://files.zeth.net/emacs.txt