Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
An Emacs Cheatsheet (for me, not you)

Get Help

  • C-h f function-name function by name
  • C-h k key-sequence function name for key
  • C-h w function-name where bound by name

Move around:

  • C-x arrow-key

NREPL Clojure

More here on the nrepl page.

  • M-x nrepl-jack-in or C-c M-j
  • C-c C-k Eval bufer in repl
  • C-c C-e Eval form preceding point in repl and display result in echo area
  • C-c C-r Eval region and display result in the echo area
  • C-c M-n Switch namespace of repl buffer to the ns of current buffer
  • C-c C-z Switch to repl.
  • M-C-x Eval for at point in repl.
  • C-c C-d Show docstring for symbol at point.
  • C-c C-s Show source for symbol at point.
  • C-c C-j Show javadoc for symbol at point.
  • M-. Jump to definition of a symbol.
  • M-, Return to pre-jump location.
  • M-Tab Completion

Javert Inspect

  • C-c i will show the contents


  • C-c C-r Run sketch

Copy / Paste

  • M-C-space Copy form beginning at point (go to start of form first)
  • C-y Yank (paste) from killring
  • M-y Cycle after initial yank
  • C-space Start mark
  • M-w Copy marked region
  • C-w Cut marked region to killring

Comment / uncomment

  • C-c C-; comment/uncomment region
  • C-c C-/ toggle comment line (used to be M-/)

Evil (Vim Compatibility) Mode

  • M-x evil-mode Turn on evil-mode
  • C-z Switch back to Emacs state , and again to switch back to Normal state
  • C-z M-x evil-mode Turn off evil-mode


  • C-x g Magit
  • s to stage something
  • c to commit all staged things
  • C-c C-c to commit
  • C-c C-k to cancel


  • C-g Cancel
  • C-i Reindent region
  • C-x d Dired
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment