diff options
author | Noam Postavsky <npostavs@gmail.com> | 2015-03-15 15:14:04 -0400 |
---|---|---|
committer | Noam Postavsky <npostavs@gmail.com> | 2015-03-15 15:14:04 -0400 |
commit | 1f20acfd57e93fd749c536dc24f5dcfdbe43e417 (patch) | |
tree | ec95483dc256e7d2205ec5ab8924c30800287413 /lisp/use-package | |
parent | 81f5e48d328e209631c6ec2588fe8d29e3c7053b (diff) | |
download | emacs-1f20acfd57e93fd749c536dc24f5dcfdbe43e417.tar.gz emacs-1f20acfd57e93fd749c536dc24f5dcfdbe43e417.tar.bz2 emacs-1f20acfd57e93fd749c536dc24f5dcfdbe43e417.zip |
use--package: eval-after-load name
instead of name-string. This prevents triggering by config file names
that have the same name as the package.
Reprise of c6d79d2cb40bd141f62eaca6dca47fb2e8e6943f
Diffstat (limited to 'lisp/use-package')
-rw-r--r-- | lisp/use-package/use-package.el | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lisp/use-package/use-package.el b/lisp/use-package/use-package.el index e4ef0048e59..36021b4d520 100644 --- a/lisp/use-package/use-package.el +++ b/lisp/use-package/use-package.el @@ -336,7 +336,7 @@ the user specified.") (ignore (display-warning 'use-package (format ,fmt ,err) :error))))))) -(defun use--package (name-symbol name-string args) +(defun use--package (name name-symbol name-string args) "See docstring for `use-package'." (let* ((commands (plist-get args :commands)) @@ -431,7 +431,7 @@ the user specified.") ,(format "Configuring package %s" name-string) ,@config-body))) - (list `(eval-after-load ,name-string + (list `(eval-after-load ',name ',body))))) `((use-package-with-elapsed-timer ,(format "Loading package %s" name-string) @@ -522,7 +522,7 @@ this file. Usage: ;; At this point, we can expand the macro using the helper function. ;; `use--package'. (let* - ((body (use--package name-symbol name-string args*)) + ((body (use--package name name-symbol name-symbol args*)) (pred (plist-get args* :if)) (expansion (if pred `(when ,pred ,@body) |