From: Masahiro Nakamura Date: Wed, 14 Oct 2020 04:14:33 +0000 (+0200) Subject: Improve package install/delete button action X-Git-Tag: emacs-28.0.90~5644 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=f256687bd4f0de8a09c1372ecf0bef917ff56277;p=emacs.git Improve package install/delete button action * lisp/emacs-lisp/package.el (package-install-button-action) (package-delete-button-action): Run describe-package instead of revert-buffer in order to use newer package-desc (bug#43983). --- diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el index 1f81e07754b..5b7735125f5 100644 --- a/lisp/emacs-lisp/package.el +++ b/lisp/emacs-lisp/package.el @@ -2630,8 +2630,7 @@ Used for the `action' property of buttons in the buffer created by (when (y-or-n-p (format-message "Install package `%s'? " (package-desc-full-name pkg-desc))) (package-install pkg-desc nil) - (revert-buffer nil t) - (goto-char (point-min))))) + (describe-package (package-desc-name pkg-desc))))) (defun package-delete-button-action (button) "Run `package-delete' on the package BUTTON points to. @@ -2641,8 +2640,7 @@ Used for the `action' property of buttons in the buffer created by (when (y-or-n-p (format-message "Delete package `%s'? " (package-desc-full-name pkg-desc))) (package-delete pkg-desc) - (revert-buffer nil t) - (goto-char (point-min))))) + (describe-package (package-desc-name pkg-desc))))) (defun package-keyword-button-action (button) "Show filtered \"*Packages*\" buffer for BUTTON.