From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Dario Gjorgjevski Newsgroups: gmane.emacs.bugs Subject: bug#38085: [PATCH] Two functions named =?UTF-8?Q?=E2=80=98package-menu--refresh=E2=80=99?= Date: Wed, 06 Nov 2019 10:50:36 +0100 Message-ID: References: <87o8xp1hdu.fsf@ip-10-207-252-54.us-west-2.compute.internal> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="260010"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: 38085@debbugs.gnu.org To: Tino Calancha Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Nov 06 10:52:32 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iSHzM-0015Vb-2t for geb-bug-gnu-emacs@m.gmane.org; Wed, 06 Nov 2019 10:52:32 +0100 Original-Received: from localhost ([::1]:54567 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iSHzK-0007nl-Uj for geb-bug-gnu-emacs@m.gmane.org; Wed, 06 Nov 2019 04:52:30 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:34155) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iSHxw-00062X-0c for bug-gnu-emacs@gnu.org; Wed, 06 Nov 2019 04:51:05 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iSHxu-0003xQ-Lx for bug-gnu-emacs@gnu.org; Wed, 06 Nov 2019 04:51:03 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:58901) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iSHxu-0003xK-Dz for bug-gnu-emacs@gnu.org; Wed, 06 Nov 2019 04:51:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1iSHxu-0004ly-9o for bug-gnu-emacs@gnu.org; Wed, 06 Nov 2019 04:51:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Dario Gjorgjevski Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 06 Nov 2019 09:51:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 38085 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 38085-submit@debbugs.gnu.org id=B38085.157303384818324 (code B ref 38085); Wed, 06 Nov 2019 09:51:02 +0000 Original-Received: (at 38085) by debbugs.gnu.org; 6 Nov 2019 09:50:48 +0000 Original-Received: from localhost ([127.0.0.1]:39489 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iSHxf-0004lU-Ue for submit@debbugs.gnu.org; Wed, 06 Nov 2019 04:50:48 -0500 Original-Received: from mail-wr1-f46.google.com ([209.85.221.46]:33220) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iSHxb-0004lF-UG for 38085@debbugs.gnu.org; Wed, 06 Nov 2019 04:50:46 -0500 Original-Received: by mail-wr1-f46.google.com with SMTP id w30so2221226wra.0 for <38085@debbugs.gnu.org>; Wed, 06 Nov 2019 01:50:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=lXk92qx7XnaMu7m4bE5T2amc0A3rh6WQwSXjhh81U2c=; b=SaUQVLAxoRV5L7MBLN6aTc+oHC4vzdhatsWy//vVfmDeEG97S3C2pvdQrl97uv/ggM wRW4Ew5nCzgAw5mB50RIsc2RquHRyqfnt4GH1TZ/qlqeHEAcz/YUBqFhTk4YR62yIm5l p5mmug+7bPyolGRyHlILhyJq/g+YBqQoiBOwsBdEkjTr7QMpl0GcL+VS8A/PMwRpELWQ JQvfLjlIHFmDK83IzG7NoD8Mkz/f6CaEaZl1RO4VxrkNphXKGk6UEZ8Brh4JgdwgoTfe /AdWp3EnFg2Pg7ejYd4LSF55xCH4NS+Op3hlkM8tpi16PuD1eqGOE3FmOfZRGFHmb7FK 31Hg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=lXk92qx7XnaMu7m4bE5T2amc0A3rh6WQwSXjhh81U2c=; b=SkC8p9HUC9pMoKGLdL0vIxrTqNB6s9expuAfCggV+sVeAk2Wci+N1EzLRloLGRqYlE wZV6gGVxz2koE6djas7lgDjz2o4sfjS1E2i87fV6OsDy8jsV553jvmvvwmjfv0nW73W2 eYtSt3r7rXnuULDHUENDZ5iFVImocoARcFvFe+cihlIcOQ3x4Sy4gN7+WOFDhCi6/kCg P+4blGgfAXDIsmndxGJYx1bIoy7OzWZvRY8X88YUtxZ5WeTMYBCwAW5A3nZE3/LBm4Ea CH897wxaHWq8xu+Rkj36/dGhRxku84ionKWk6Xh0Q/HCDci5OuPBIFoD2KjdJ8rTASfv wDkw== X-Gm-Message-State: APjAAAX4bb8ploal/nqirlFluPyYgy8S2iUdpeskmJNCxfiwg6tAAbia DYDDgOxYK2NjBMaBoPJBl/pzM86o X-Google-Smtp-Source: APXvYqxvC9+Ciy/MleJaF2F/P4MmJx/IytQKYM+XBLNzkipOlHEoJ9Yyn4Q40ZehNJaEDSn2+8l8RQ== X-Received: by 2002:a5d:6390:: with SMTP id p16mr1642772wru.55.1573033837710; Wed, 06 Nov 2019 01:50:37 -0800 (PST) Original-Received: from ZALANDO-31298 ([185.85.220.254]) by smtp.gmail.com with ESMTPSA id h140sm2816183wme.22.2019.11.06.01.50.36 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 06 Nov 2019 01:50:36 -0800 (PST) In-Reply-To: <87o8xp1hdu.fsf@ip-10-207-252-54.us-west-2.compute.internal> (Tino Calancha's message of "Wed, 06 Nov 2019 09:30:37 +0000") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:171017 Archived-At: --=-=-= Content-Type: text/plain Tino Calancha writes: > I mean, this is bug 38084 Thanks; I did not realize that there is already a bug. Here is an amended patch which references bug#38084 in the commit message. --=-=-= Content-Type: text/x-diff; charset=utf-8 Content-Disposition: inline; filename=0001-Disambiguate-package-menu-refresh-bug-38084.patch Content-Transfer-Encoding: quoted-printable Content-Description: Disambiguate `package-menu--refresh' >From 5b648752499a528ed23f257deccb4a4f5ef0d009 Mon Sep 17 00:00:00 2001 From: Dario Gjorgjevski Date: Wed, 6 Nov 2019 09:53:38 +0100 Subject: [PATCH] =3D?UTF-8?q?Disambiguate=3D20=3DE2=3D80=3D98package-menu--= refresh?=3D =3D?UTF-8?q?=3DE2=3D80=3D99=3D20(bug#38084)?=3D MIME-Version: 1.0 Content-Type: text/plain; charset=3DUTF-8 Content-Transfer-Encoding: 8bit * lisp/emacs-lisp/package.el (package-menu--refresh, package-menu--refresh): Rename to =E2=80=98package-menu--refresh-entries=E2= =80=99 and =E2=80=98package-menu--refresh-contents=E2=80=99 in order to disambiguate t= he two. --- lisp/emacs-lisp/package.el | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el index b7a528dac4..b35fe022de 100644 --- a/lisp/emacs-lisp/package.el +++ b/lisp/emacs-lisp/package.el @@ -2765,9 +2765,9 @@ package-menu-mode ("Description" 0 package-menu--description-predicate)]) (setq tabulated-list-padding 2) (setq tabulated-list-sort-key (cons "Status" nil)) - (add-hook 'tabulated-list-revert-hook #'package-menu--refresh nil t) + (add-hook 'tabulated-list-revert-hook #'package-menu--refresh-entries ni= l t) (tabulated-list-init-header) - (setq revert-buffer-function 'package-menu--refresh) + (setq revert-buffer-function 'package-menu--refresh-contents) (setf imenu-prev-index-position-function #'package--imenu-prev-index-position-function) (setf imenu-extract-index-name-function @@ -2926,7 +2926,7 @@ package-hidden-regexps :version "25.1" :type '(repeat (regexp :tag "Hide packages with name matching"))) =20 -(defun package-menu--refresh (&optional packages keywords) +(defun package-menu--refresh-entries (&optional packages keywords) "Re-populate the `tabulated-list-entries'. PACKAGES should be nil or t, which means to display all known packages. KEYWORDS should be nil or a list of keywords." @@ -3039,7 +3039,7 @@ package-menu--generate =20 With KEYWORDS given, only packages with those keywords are shown." - (package-menu--refresh packages keywords) + (package-menu--refresh-entries packages keywords) (setf (car (aref tabulated-list-format 0)) (if keywords (let ((filters (mapconcat #'identity keywords ","))) @@ -3166,7 +3166,7 @@ package-menu--print-info-simple (defvar package-menu--old-archive-contents nil "`package-archive-contents' before the latest refresh.") =20 -(defun package-menu--refresh (&optional _arg _noconfirm) +(defun package-menu--refresh-contents (&optional _arg _noconfirm) "In Package Menu, download the Emacs Lisp package archive. Fetch the contents of each archive specified in `package-archives', and then refresh the package menu. Signal a @@ -3646,7 +3646,7 @@ list-packages (package-menu-mode) =20 ;; Fetch the remote list of packages. - (unless no-fetch (package-menu--refresh)) + (unless no-fetch (package-menu--refresh-contents)) =20 ;; If we're not async, this would be redundant. (when package-menu-async @@ -3706,7 +3706,7 @@ package-menu-filter-by-name (package-show-package-list t nil) ;; Update `tabulated-list-entries' so that it contains all ;; packages before searching. - (package-menu--refresh t nil) + (package-menu--refresh-entries t nil) (let (matched) (dolist (entry tabulated-list-entries) (let* ((pkg-name (package-desc-name (car entry)))) --=20 2.17.1 --=-=-=--