Skip to content

Instantly share code, notes, and snippets.

@papachan
Last active May 23, 2020 14:11
Show Gist options
  • Save papachan/99a89ed85dfa2482d7c0 to your computer and use it in GitHub Desktop.
Save papachan/99a89ed85dfa2482d7c0 to your computer and use it in GitHub Desktop.
Keybinding Description
C-h C-a help start screen
C-x C-c save-buffers-kill-emacs (exit emacs)
C-g keyboard-quit
M-esc esc keyboard-escape-quit
C-x z Magic. repeat last operation
M-! shell command
ESC ! shell-command
ESC x compile compile ("make -k" is default)
C-x ` next-error(used after "compile" to find/edit errors)
C-u universal-argument
C-x C-z suspend-emacs(resume by typing "fg" to unix)
C-h help-command
C-h t help-with-tutorial
C-h b describe-bindings(complete list of emacs commands)
C-x h TAB indent all lines
C-c C-k compile code
C-c , run test
C-c M-j connected to repl
C-x * c start calculator
C-h m Show describe mode
C-x C-- transform frame
C-x C-+ transform frame
C-x { make window taller
C-x } enlarge-window-horizontally make window wider
C-u 4 0 C-x 3 open a window with a fixed width
C-c C-e export - only in org-mode
C-x C-s save the current file without confirmation
C-x C-w write your file (save as)
C-x C-f Open (Find) a file
C-x C-w Save As
C-x s Save any unsaved files
C-x C-c exit the emacs (but save files first)
C-a go to the beginning-of-line
C-e go to: end-of-the-line
M-a navigate between blocks
M-e go to the block end
Shift M-e Select whole paragraph
C-n go to next-line
C-p go to previous-line
C-x l line count of current file
C-k positionate at the begin of line & kill the current line
C-Shift-backspace kill whole line
M-k kill whole block text
C-t switch with previous char
C-c o Insert a new line above
C-o Insert a new line (open-line)
C-q C-j insert end of line
C-x C-g go to a specific line numbered x
C-x C-w show (in the minibuffer ) the current line number
ESC d kill-word
ESC f forward-word
ESC b backward-word
ESC DEL backward-kill-word
C-f forward-char
C-b backward-char
C-d delete-char
DEL delete-backward-char
C-q quoted-insert
C-t transpose-chars
C-x C-o delete next line
C-space set a region mark
C-w kill-region (between cursor and mark)
ESC-w memorize the contents of the region (without kill)
C-y yank (i.e., insert text last killed or memorize)
C-l recenter
C-v scroll-up (forward)
ESC-v scroll-down (backward)
ESC < beginning-of-buffer
ESC > end-of-buffer
C-x C-f find-file
C-x C-r find-file-read-only
C-x C-s save-current-file
C-c p s g Projectile Run grep on the files in the project.
C-x 1 delete-other-windows
C-x 2 split-window-vertically
C-x 4 f find-file-other-window
C-x o other-window
C-x 3 split window
C-x o change window focus
C-x C-f open a file
M-1 change to window number
C-c C-e Export pdf after: l p
C-x m Compose a new email
C-s search
C-r reverse search
C-x e eshell emacs shell (find-file)
C-S backspace delete a line
C-c w C-x rd delete a marked region
C-x u Undo-tree
C-_ C-/ undo-tree-undo Undo changes.
M-_ C-? undo-tree-redo Redo changes.
M-f move word forward
M-b move previous word
C-a move to the beginning of the line
C-e move to end of the line
M-a move to the beginning of sentence
M-e move forward to the end of sentence
M-0 M-r Top of window
M-- M-r Bottom of window
M-> Top of buffer
M-< Bottom of buffer
M-c Capitalize word
M-u Uppercase
M-l Lowercase
C-x C-l lower case a region
C-x C-u uppercase a region
C-x C-b ibuffer
C-x b switching buffer (you can write a new buffer)
C-x C-b Quick buffer list
C-x 0 Delete the current window
C-x 1 close other window
C-x 2 split buffer into two windows horizontally
C-x 3 split-window-right split buffer into two windows vertically
C-x 4 f find a file in other window
C-x 4 b switch buffer in other window
C-x 5 2 make-frame-command
C-u 40 = insert a line of 40 =
C-q 361 ñ
C-c C-c magit commit
C-SPC just C-SPC and mark the region you want to commit and s or SHIFT+ arrows and s
C-x d open dired and path directory
C-x C-j navigate all dired buffers
C-x C-d just list a directory
C-x 4 d open a new dired frame
C-x C-q M-x dired-toggle-read-only after C-c C-c to exit
C-space select region
C-c w select whole line (if shortcuts exists)
C-w cut
M-w copy
C-y paste
C-x rd delete inside rectangle
C-x rt edit a column on a multiple lines
C-x h select all file
C-Space C-x rt (write something) Enter
M- Dictionary
C-x l show all the lines
M-q Justify text
C-q C-j insert a new line above
C-x [arrow < >] buffer/window navigation
C-x C-e eval last expression
C-j eval print last expression
C-h v eval current variable
M-: eval-expression (if nil "yes" "no") eval an expression in minibuffer
C-M-x (lisp-eval-defun)
C-c C-l run a file
C-x C-f find a file
C-h f function describe
C-c M-j launch cider-jack-in
C-c M-c cider-connect
C-x b cider-repl
C-c C-e eval in minibuffer
C-c M-e eval and the result is sent to the REPL
C-x C-e eval current buffer
C-c C-k compile current file/buffer
C-c M-n Switch to namespace of the current buffer
q close cider-error
C-c C-d d show the documentaion
C-c M-n switch to namespace of current Clojure buffer
M-> M-x cider-jump-to-var
C-c C-q M-x cider-quit
M-( paredit: put parens ()
C- right arrow paredit: Slurp; forward-slurp-sexp move closing parenthesis to the right to include next expression
C- left arrow paredit: Barf; forward-barf-sexp move closing parenthesis to the left to exclude last expression
M-r paredit: raise-sexp
M- up arrow splice-sexp-killing-backward
C-M-f C-M-b Move opening / closing parenthesis
M-? convolute-sexp
M-s paredit-kill-sexp
C-k kill expression
M-q Wrap into 80 chars per columns
M-Shift-: eval
C-c C-v open file in a browser
<f2> <f2> two columns screens
C-n open a new buffer (alias 'new-empty-buffer)
C-x C-e eval expression
C-c C-d C-d documentation symbol under the cursor
C-c RET show the expansion of the macro frame
C-v cls repl
C-c C-v TAB slime inspector inside object
C-c C-c On a defun show compile errors
C-c M-o clear the repl buffer 'slime-repl-clear-buffer
C-c C-d C-d show documentation of the symbol under the cursor
C-x b switch with buffer
C-x C-r back to last edited file
M-; Comment a region
C-q C-j a string to replace (you can put a newline C-q C-j)
C-c C-j replace-string
C-x r m flag a bookmark
C-x r l list
C-x r b jump
C-h w shortcuts help
C-h b describe-bindings
C-x n n fancy narrow region
C-x n w fancy narrow widen
C-c p f find a file in project with helm
C-c c select a dir for neotree-mode
C-c psg projectile grep find in project
[f8] open neotree
C-s C-y select all match from a copied text (C-w)
C-s C-w search for next word
C-x 8 insert an accent over deadkey
C-u 66 ; create a line of ; with 66 chars C-u 66 #
C-c y 'djcb-duplicate-line
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment