lotsa changes and inclusion of elpy
[emacs.git] / .emacs.d / elisp / yasnippet / snippets / emacs-lisp-mode / minor_mode
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
8 (defvar $1-mode nil)
9 (make-variable-buffer-local '$1-mode)
10 (put '$1-mode 'permanent-local t)
11
12 (defun $1-mode (&optional arg)
13 "$0"
14 (interactive "P")
15 (setq $1-mode
16 (if (null arg) (not $1-mode)
17 (> (prefix-numeric-value arg) 0)))
18 (force-mode-line-update))
19
20 (provide '$1-mode)