Files
.emacs.d/modules/text-editing/siren-sort-symbols.el
Jim Myhrberg 87a86191db Majorly re-organize modules
- Split large modules into smaller parts (e.g. siren-text-manipulation)
- Organize modules into high level groups:
  - completion
  - core
  - editor
  - languages
  - linting
  - misc
  - navigation
  - projects
  - spelling
  - text-editing
  - version-control
  - windows
  - workspaces
2018-05-20 17:31:11 +01:00

20 lines
523 B
EmacsLisp

;;; siren-sort-symbols.el --- jimeh's Emacs Siren: sort-symbols.
;;; Commentary:
;; Helper command to sort symbols in region. Shamelessly ripped from:
;; https://www.emacswiki.org/emacs/SortWords
;;; Code:
(defun sort-symbols (reverse beg end)
"Sort symbols in region alphabetically, in REVERSE if negative.
See `sort-symbols'."
(interactive "*P\nr")
(sort-regexp-fields reverse "\\(\\sw\\|\\s_\\)+" "\\&" beg end))
(defalias 'ss 'sort-symbols)
(provide 'siren-sort-symbols)
;;; siren-sort-symbols.el ends here