Klimi's new dotfiles with stow.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
467 B

5 years ago
  1. # -*- mode: snippet -*-
  2. # name: minor_mode
  3. # key: minor
  4. # --
  5. (defvar ${1:mode}-modeline-indicator " ${2:indicator}"
  6. "call ($1-install-mode) again if this is changed")
  7. (defvar $1-mode nil)
  8. (make-variable-buffer-local '$1-mode)
  9. (put '$1-mode 'permanent-local t)
  10. (defun $1-mode (&optional arg)
  11. "$0"
  12. (interactive "P")
  13. (setq $1-mode
  14. (if (null arg) (not $1-mode)
  15. (> (prefix-numeric-value arg) 0)))
  16. (force-mode-line-update))
  17. (provide '$1-mode)