From f256687bd4f0de8a09c1372ecf0bef917ff56277 Mon Sep 17 00:00:00 2001 From: Masahiro Nakamura Date: Wed, 14 Oct 2020 06:14:33 +0200 Subject: [PATCH] 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). --- lisp/emacs-lisp/package.el | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) 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. -- 2.39.5