From: Thierry Volpiatto Date: Thu, 4 Feb 2016 09:20:55 +0000 (+0100) Subject: When :ensure is used install package as a selected package X-Git-Tag: emacs-29.0.90~1306^2~15^2~318^2~1 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=5cbfd926c5e4035fc46c17d4188015cb54204225;p=emacs.git When :ensure is used install package as a selected package Also shutup bytecompiler about package-archive-contents. * use-package.el (use-package-ensure-elpa): Add package to selected package by using second arg of package install. --- diff --git a/lisp/use-package/use-package.el b/lisp/use-package/use-package.el index dcc8842b6e9..05dbf651498 100644 --- a/lisp/use-package/use-package.el +++ b/lisp/use-package/use-package.el @@ -446,7 +446,7 @@ manually updated package." ;; ;; :ensure ;; - +(defvar package-archive-contents) (defun use-package-normalize/:ensure (name keyword args) (if (null args) t @@ -462,7 +462,7 @@ manually updated package." (if (package-installed-p package) t (if (or (assoc package package-archive-contents) no-refresh) - (package-install package) + (package-install package t) (progn (package-refresh-contents) (use-package-ensure-elpa package t)))))