Skip to content

Instantly share code, notes, and snippets.

@daviderestivo
Last active August 22, 2017 06:48
Show Gist options
  • Save daviderestivo/b3d0d8bbb782bb97ccbe7493c4079217 to your computer and use it in GitHub Desktop.
Save daviderestivo/b3d0d8bbb782bb97ccbe7493c4079217 to your computer and use it in GitHub Desktop.
Add superword mode to python-mode
;;
;; superword-mode is a minor mode that allows emacs
;; to treat a word separated by '_' as a single one
;; This might be useful for example when moving betwwen
;; words using 'Alt + F' or 'Alt + B' in python-mode
;;
(add-hook 'python-mode-hook
'(lambda ()
;; Enable superword mode, useful for “snake_case”.
(superword-mode 1)
))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment