GNU bug report logs - #34949
27.0.50; Docstring of `vc-deduce-fileset' incomplete

Previous Next

Package: emacs;

Reported by: Philipp Stephani <p.stephani2 <at> gmail.com>

Date: Fri, 22 Mar 2019 18:04:02 UTC

Severity: minor

Tags: confirmed, fixed

Found in version 27.0.50

Fixed in version 28.0.50

Done: Juri Linkov <juri <at> linkov.net>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Dmitry Gutov <dgutov <at> yandex.ru>
To: Juri Linkov <juri <at> linkov.net>
Cc: Lars Ingebrigtsen <larsi <at> gnus.org>, 34949 <at> debbugs.gnu.org
Subject: bug#34949: 27.0.50; Docstring of `vc-deduce-fileset' incomplete
Date: Sun, 15 Mar 2020 23:54:03 +0200
On 15.03.2020 1:31, Juri Linkov wrote:

>> Called dired-vc-next-action. From you earlier description, I imagined that
>> it would simply invoke a VC-Dir in all cases, but if you need to check
>> whether there are any directories selected, it would call vc-dir only in
>> that case, and delegate to vc-next-action otherwise.
>>
>> That would be a more additive change.
> 
> And the patch will be shorter.

As a consequence, yes.

>>> Then vc-dir-refresh puts all marks on files.
>>
>> Could dired-vc-next-action use vc-delayed, to then run marking code after
>> the vc-dir buffer refreshes?
> 
> Maybe it's not working since vc-dir-refresh already doesn't use
> vc-run-delayed to run vc-dir-refresh-files and vc-dir-update.

I don't know if that's the way to determine this. Doing both calls in 
the callback is a good approach which is easy for vc-dir-refresh to 
take. dired-vc-next-action couldn't do that, so vc-run-delayed could be 
the next best option. Or not, of course.

>> Or if it's not working, or not reliable enough, we can add
>> a vc-dir--after-refresh-hook. Which dired-vc-next-action would add to, and
>> vc-dir-refresh would run (the function will remove itself from the hook
>> upon completion).
> 
> Isn't vc-dir--after-refresh-hook a global variable too?

Yes, but it's a hook (and let's call it without double-dashes, it was 
just a typo on my part, sorry).

I guess the main thing I didn't like is that vc-dir-refresh took the 
value of some global variable and started doing things with it, for no 
hugely apparent reason.

The hook will allow us to move almost all of the new code to the place 
where its purpose is more obvious. And that's a good thing.

>>> Also the patch adds a new useful global keybinding 'C-x v V'
>>> bound to vc-next-action-on-root to open *vc-dir* buffer where
>>> all registered files are marked.
>>
>> Sounds more like vc-dir-root-with-registered-files-selected. I wouldn't
>> call it "next action" because it only provides one action.
> 
> Maybe then a shorter name vc-root-dir-action?

The word "action" there seems to hold no particular meaning.

vc-root-dir-with-dwim-selection, maybe?




This bug report was last modified 5 years and 37 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.