mirror of
https://github.com/masscollaborationlabs/emacs.git
synced 2025-07-06 04:09:37 +00:00
Add new customization option use-package-always-demand
This is equivalent to adding `:demand t` to all `use-package` declarations, and has the same semantics as doing so (meaning it can be overridden locally using `:defer t` in a declaration). Fixes https://github.com/jwiegley/use-package/issues/423
This commit is contained in:
parent
dbf46d97be
commit
ad8094c22d
1 changed files with 9 additions and 1 deletions
|
@ -80,6 +80,11 @@ The check is performed by looking for the module using `locate-library'."
|
||||||
:type 'boolean
|
:type 'boolean
|
||||||
:group 'use-package)
|
:group 'use-package)
|
||||||
|
|
||||||
|
(defcustom use-package-always-demand nil
|
||||||
|
"If non-nil, assume `:demand t` unless `:defer t` is given."
|
||||||
|
:type 'boolean
|
||||||
|
:group 'use-package)
|
||||||
|
|
||||||
(defcustom use-package-always-ensure nil
|
(defcustom use-package-always-ensure nil
|
||||||
"Treat every package as though it had specified `:ensure SEXP`."
|
"Treat every package as though it had specified `:ensure SEXP`."
|
||||||
:type 'sexp
|
:type 'sexp
|
||||||
|
@ -1171,7 +1176,10 @@ this file. Usage:
|
||||||
|
|
||||||
(let ((body
|
(let ((body
|
||||||
(macroexp-progn
|
(macroexp-progn
|
||||||
(use-package-process-keywords name args*
|
(use-package-process-keywords name
|
||||||
|
(if use-package-always-demand
|
||||||
|
(append args* '(:demand t))
|
||||||
|
args*)
|
||||||
(and use-package-always-defer (list :deferred t))))))
|
(and use-package-always-defer (list :deferred t))))))
|
||||||
(if use-package-debug
|
(if use-package-debug
|
||||||
(display-buffer
|
(display-buffer
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue