X-Git-Url: https://git.shemshak.org/gitweb.cgi/~bandali/configs/blobdiff_plain/3b3615f5761d8949046d65906d3f324eec9b18e8..5e73fac6f4bcbc6268d546a89658c0b15a5eefe7:/.emacs.d/init.el diff --git a/.emacs.d/init.el b/.emacs.d/init.el index 4002d9a..6210f90 100644 --- a/.emacs.d/init.el +++ b/.emacs.d/init.el @@ -1518,7 +1518,16 @@ This function is intended for use with `ivy-ignore-buffers'." (add-to-list 'yas-snippet-dirs "~/src/git/guix/etc/snippets" t) (yas-reload-all) (setq yas-verbosity yas-verbosity-cur) - (define-key yas-minor-mode-map (kbd "SPC") yas-maybe-expand) + + (defun b/yas--maybe-expand-key-filter (cmd) + (when (and (yas--maybe-expand-key-filter cmd) + (not (bound-and-true-p git-commit-mode))) + cmd)) + (defconst b/yas-maybe-expand + '(menu-item "" yas-expand :filter b/yas--maybe-expand-key-filter)) + (define-key yas-minor-mode-map + (kbd "SPC") b/yas-maybe-expand) + (yas-global-mode)) (use-package debbugs)