Move which-key footnote replacement to lisp/bandali-message.el.
[~bandali/configs] / lisp / bandali-yasnippet.el
... / ...
CommitLineData
1(use-package yasnippet
2 :defer 0.6
3 :config
4 (declare-function yas-reload-all
5 "yasnippet" (&optional no-jit interactive))
6 (declare-function yas-maybe-expand-abbrev-key-filter
7 "yasnippet" (cmd))
8
9 (defconst yas-verbosity-cur yas-verbosity)
10 (setq yas-verbosity 2)
11 (add-to-list 'yas-snippet-dirs "~/src/git/guix/etc/snippets" t)
12 (yas-reload-all)
13 (setq yas-verbosity yas-verbosity-cur)
14
15 (defun b/yas-maybe-expand-abbrev-key-filter (cmd)
16 (when (and (yas-maybe-expand-abbrev-key-filter cmd)
17 (not (bound-and-true-p git-commit-mode)))
18 cmd))
19 (defconst b/yas-maybe-expand
20 '(menu-item "" yas-expand :filter b/yas-maybe-expand-abbrev-key-filter))
21 (define-key yas-minor-mode-map
22 (kbd "SPC") b/yas-maybe-expand)
23
24 (yas-global-mode))
25
26(provide 'bandali-yasnippet)