diff options
author | David Morgan <djm_uk@protonmail.com> | 2022-10-17 16:07:30 +0100 |
---|---|---|
committer | David Morgan <djm_uk@protonmail.com> | 2022-10-17 16:07:30 +0100 |
commit | a020f453ccf0c9fd0b240403087996a50d3f7eff (patch) | |
tree | c25ec31987f8d70743740883d596c2ed11a40fe9 | |
parent | 6efcee4e88d3fe2548e5ad331e9d585485ff681e (diff) | |
download | dotfiles-a020f453ccf0c9fd0b240403087996a50d3f7eff.tar.gz |
Move use-extension macro to init-packages
-rw-r--r-- | .emacs.d/lisp/init-completion.el | 10 | ||||
-rw-r--r-- | .emacs.d/lisp/init-packages.el | 11 |
2 files changed, 11 insertions, 10 deletions
diff --git a/.emacs.d/lisp/init-completion.el b/.emacs.d/lisp/init-completion.el index 2c8d00d..7277ca0 100644 --- a/.emacs.d/lisp/init-completion.el +++ b/.emacs.d/lisp/init-completion.el @@ -141,16 +141,6 @@ no words in between, beginning with the first word." ([backtab] . corfu-previous)) :hook (emacs-startup . global-corfu-mode)) -(defmacro use-extension (pkg name &rest args) - "Like `use-package', but for a package extension. -`PKG' is the name of the package, `NAME' and `ARGS' are as with `use-package'" - (declare (indent defun)) - `(use-package ,name - :straight nil - :after pkg - :demand t - ,@args)) - (use-extension corfu corfu-indexed :config (corfu-indexed-mode 1)) diff --git a/.emacs.d/lisp/init-packages.el b/.emacs.d/lisp/init-packages.el index 6b69f18..4c6211a 100644 --- a/.emacs.d/lisp/init-packages.el +++ b/.emacs.d/lisp/init-packages.el @@ -39,6 +39,17 @@ (use-feature straight-x :commands (straight-x-fetch-all)) +;; useful for corfu and vertico extenions +(defmacro use-extension (pkg name &rest args) + "Like `use-package', but for a package extension. +`PKG' is the name of the package, `NAME' and `ARGS' are as with `use-package'" + (declare (indent defun)) + `(use-package ,name + :straight nil + :after pkg + :demand t + ,@args)) + (use-package diminish) (defun run-straight-lock-file-function (func) |