From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#34949: 27.0.50; Docstring of `vc-deduce-fileset' incomplete Date: Sun, 29 Mar 2020 01:54:22 +0200 Organization: LINKOV.NET Message-ID: <878sjkjb8p.fsf@mail.linkov.net> References: <87fteyl64x.fsf@mail.linkov.net> <47fcc86a-a884-0658-d1cb-8666704924e8@yandex.ru> <87o8tkgbe2.fsf@mail.linkov.net> <8736avy640.fsf@mail.linkov.net> <76e52ade-bb44-427a-0910-3fe3cf65bf6d@yandex.ru> <87a751uonw.fsf@mail.linkov.net> <9bab3a53-ec31-3300-132f-dc1e17ee0c53@yandex.ru> <875zfd9lzm.fsf@mail.linkov.net> <87mu8mieve.fsf@mail.linkov.net> <87k13pkxdl.fsf@mail.linkov.net> <207d4e30-aa59-b8eb-c39a-0957757f39eb@yandex.ru> <875zf6cy3w.fsf@mail.linkov.net> <9c39f788-29f1-5a68-c8f3-a4b08ae9ea3b@yandex.ru> <87lfo1dvcf.fsf@mail.linkov.net> <44cda45a-db93-f2c1-626d-9ace68cd6fd1@yandex.ru> <87y2rpqt28.fsf@mail.linkov.net> <874kuci4tx.fsf@mail.linkov.net> <786821a9-ceab-bbe8-b02a-69e77ddde426@yandex.ru> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="88633"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu) Cc: Lars Ingebrigtsen , 34949@debbugs.gnu.org To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Mar 30 04:37:44 2020 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 1jIkJ5-000Mxw-CJ for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 30 Mar 2020 04:37:43 +0200 Original-Received: from localhost ([::1]:43750 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jIkJ4-0005pZ-A5 for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 29 Mar 2020 22:37:42 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:54929) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jIkHr-0003dj-4m for bug-gnu-emacs@gnu.org; Sun, 29 Mar 2020 22:36:28 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jIkHp-0003bC-TJ for bug-gnu-emacs@gnu.org; Sun, 29 Mar 2020 22:36:27 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:48641) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jIkHp-0003ay-PM for bug-gnu-emacs@gnu.org; Sun, 29 Mar 2020 22:36:25 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jIkHp-0004ht-NB for bug-gnu-emacs@gnu.org; Sun, 29 Mar 2020 22:36:25 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 30 Mar 2020 02:36:25 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 34949 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: confirmed Original-Received: via spool by 34949-submit@debbugs.gnu.org id=B34949.158553573417384 (code B ref 34949); Mon, 30 Mar 2020 02:36:25 +0000 Original-Received: (at 34949) by debbugs.gnu.org; 30 Mar 2020 02:35:34 +0000 Original-Received: from relay1-d.mail.gandi.net ([217.70.183.193]:4017) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jILWs-00048o-Bv for 34949@debbugs.gnu.org; Sat, 28 Mar 2020 20:10:18 -0400 X-Originating-IP: 91.129.96.173 Original-Received: from mail.gandi.net (m91-129-96-173.cust.tele2.ee [91.129.96.173]) (Authenticated sender: juri@linkov.net) by relay1-d.mail.gandi.net (Postfix) with ESMTPSA id D827A240005; Sun, 29 Mar 2020 00:10:11 +0000 (UTC) In-Reply-To: <786821a9-ceab-bbe8-b02a-69e77ddde426@yandex.ru> (Dmitry Gutov's message of "Sat, 28 Mar 2020 00:41:09 +0200") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-List-Received-Date: Sun, 29 Mar 2020 00:10:18 -0000 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:177843 Archived-At: >>> * r vc-dir-mark-registered >>> * u vc-dir-mark-unregistered >>> ... >> This is implemented as well: > > Here's a somewhat more subtle option for your consideration: > > Personally, I'm likely to never use vc-dir-mark-unregistered because I tend > to leave unregistered files around (ones that should really be in > gitignore, but it's a pain to add them). And adding unregistered files > one-by-one is not too much trouble, it's a relatively rare operation (or > you can always use 'M'). So I would leave that command unbound. Indeed, marking unregistered files should not be a frequent operation. > Marking "registered" files, though, could be made more streamlined. Right > now I have to navigate to files in all different statuses present in the > current repo and press 'M' for each status. > > However! vc-dir-mark-all-files has a special behavior when it's called with > C-u: it tries to mark all files in the current VC-Dir buffer. Or equivalent behavior is when typing 'M' at the top of VC-Dir buffer. > Which is pretty useless when we also have files in incompatible > statuses because vc-next-action fails with that fileset. > > So what we could do, is have vc-dir-mark-all-files call > vc-dir-mark-registered in that case instead. This way the former command > becomes significantly more useful, and the latter one doesn't really need > a separate key binding. And I'm sure 'C-u M' would become quite handy. I don't see a need to rely on vc-dir-mark-registered then. vc-dir-mark-all-files could work in two passes: first to check if there are some unregistered files, then on the second pass ignore unregistered files and mark only registered files. In any case the logic becomes more complicated. Actually on second thought: no way since vc-dir-mark-all-files can't guess user's intention: whether the user wants to mark all registered files to commit them, or the user wants to mark all unregistered files to register them. So maybe better to leave vc-dir-mark-all-files alone?