From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Philip Kaludercic Newsgroups: gmane.emacs.bugs Subject: bug#55470: [PATCH] Add package-delete-regexp Date: Thu, 19 May 2022 14:26:17 +0000 Message-ID: <87y1yx1tva.fsf@posteo.net> References: <87y1yytoqh.fsf@posteo.net> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="21147"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 55470@debbugs.gnu.org To: "Marwan L." Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu May 19 16:27:12 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nrh7P-0005IE-VY for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 19 May 2022 16:27:12 +0200 Original-Received: from localhost ([::1]:44102 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nrh7O-0003nD-Vb for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 19 May 2022 10:27:10 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:47470) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nrh7G-0003k4-1a for bug-gnu-emacs@gnu.org; Thu, 19 May 2022 10:27:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:42464) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nrh7F-0005rD-PQ for bug-gnu-emacs@gnu.org; Thu, 19 May 2022 10:27:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nrh7F-0002tT-IF for bug-gnu-emacs@gnu.org; Thu, 19 May 2022 10:27:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Philip Kaludercic Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 19 May 2022 14:27:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 55470 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch moreinfo Original-Received: via spool by 55470-submit@debbugs.gnu.org id=B55470.165297038911069 (code B ref 55470); Thu, 19 May 2022 14:27:01 +0000 Original-Received: (at 55470) by debbugs.gnu.org; 19 May 2022 14:26:29 +0000 Original-Received: from localhost ([127.0.0.1]:36357 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrh6i-0002sQ-Jw for submit@debbugs.gnu.org; Thu, 19 May 2022 10:26:28 -0400 Original-Received: from mout01.posteo.de ([185.67.36.65]:45769) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrh6f-0002s8-Dn for 55470@debbugs.gnu.org; Thu, 19 May 2022 10:26:27 -0400 Original-Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 1D2D7240026 for <55470@debbugs.gnu.org>; Thu, 19 May 2022 16:26:18 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1652970379; bh=rRGDOV6HAhfUwQu3b4E2SAlYKs+ZyOSwBzndGdyRs7I=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=ZeLIjkWigCk7VdD4965VyuKoARSTEzIwhE35cYj7Drlz/eMraoWcZE9183s4rCPov XIPQlFu1ZZ9GN2BQvYhLKSpfIPLsrshVUUyz7Azc/n6HPTZoal9sA007x94Wr50J7k uQzv7V12jS5n5Rf6gSN1czhwLaAlBWEs5qfDpn0WKOY5ZWQEdXlZ07F7kmjPKnSsPM DfrzAfd96QYIGqYz3Vlx95LAHCT9JyPqnlyMN2G/v4ngLuf79eBq7Gnes13oKrVmLx oC3weYdQ+QyIhNeLcTTsbXC+YKkIWB6SbBpb70omU7nWoQeKTJrC9ad8LTTVQM94mQ /4iAUVYCburGQ== Original-Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4L3sbt1gGLz9rxT; Thu, 19 May 2022 16:26:18 +0200 (CEST) X-Hashcash: 1:20:220519:55470@debbugs.gnu.org::TGLKj9TOK115H2ms:00000000000000000000000000000000000000006dik X-Hashcash: 1:20:220519:techmetx11@disroot.org::/oOWhiqTJEVdgwSV:0000000000000000000000000000000000000007CEf Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB In-Reply-To: (Marwan L.'s message of "Thu, 19 May 2022 13:04:34 +0100") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:232650 Archived-At: "Marwan L." writes: > On Wed, May 18, 2022 at 11:17:26PM +0000, Philip Kaludercic wrote: >> "Marwan L." writes: >> >> > This function allows you to delete packages, with names that match the >> > regexp. This is makes operations like deleting multiple packages that >> > begin with the same namespace (^company.*, ^treemacs.*, etc.) much >> > easier to do >> >> What is the advantage of a separate function for deleting packages >> compared to marking packages in the *Packages* buffer using "/ n" (that >> also accepts a regular expression)? > > It depends on how much packages you have to go through. If you have tons > of packages to mark deletion on, then it will most likely involve > holding d (wish you could do C-u 100 d) and then doing x Apparently the prefix argument does not work, though you can do the same with a macro. Maybe adding a "t" to toggle the selection, though this would be a very specific use-case. What do you think about extending the package-menu-filter commands with a way to mark all packages instead of filtering? > `M-x list-packages` will also automatically fetch the latest list of > packages from your package archives, which is unnecessary > > There's a prefix argument that disables fetching, but I didn't know that > before making this function nor this patch There is also M-x package-list-packages-no-fetch. > You are free to close this patch if you want to No, that is not my intention, I just wanted to clarify a point. >> >> > The function will also tell you how much packages it will delete (in a >> > temporary buffer) and prompt for a Yes or No answer