GNU bug report logs - #12159
24.1.50; vc-dir: Need a way to hide unregistered files

Previous Next

Package: emacs;

Reported by: Jambunathan K <kjambunathan <at> gmail.com>

Date: Wed, 8 Aug 2012 18:16:02 UTC

Severity: wishlist

Tags: patch

Merged with 6148

Found in version 24.1.50

Fixed in version 24.3

Done: Glenn Morris <rgm <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Jambunathan K <kjambunathan <at> gmail.com>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: Glenn Morris <rgm <at> gnu.org>, 12159 <at> debbugs.gnu.org
Subject: bug#12159: 24.1.50; vc-dir: Need a way to hide unregistered files
Date: Mon, 13 Aug 2012 23:16:23 +0530
[Message part 1 (text/plain, inline)]
FWIW, I am attaching two patches.  If you want any changes please do it
yourself.

patch-1 :: There is only one command 'x' - which hides state at point.
patch-2 :: `x' hides up-to-date and `C-u x' hides state at point.

Personally, I will go with patch 1.  It is simpler.  No prefix key is
used.

Btw, reviewer who takes infinite time to review could either be a
perfectionist or a procrastinator :-).

[bug#12159-approach-1.patch (text/x-diff, attachment)]
[bug#12159-approach-2.patch (text/x-diff, attachment)]
[Message part 4 (text/plain, inline)]
>> +	* vc/vc-dir.el (vc-dir-hide-these-states): New custom variable.
>
> Don't bother.  Just always default to up-to-date.
>
>> +(defun vc-dir-hide-some-states (&optional states)
>
> Make it `state' and not a list.
>
>> +  (interactive
>> +   ;; Interactive use.
>
> Redundant comment.
>
>> +  ;; Non-interactive use.
>> +  (unless (called-interactively-p 'any)
>> +    (setq states (or states vc-dir-hide-these-states)))
>
> The test is wrong (it prevents non-interactive use where you specify
> the state explicitly).
> The above should simply be (unless state (setq state 'up-to-date)).
>
>> +(defun vc-dir-hide-up-to-date ()
>> +  "Hide up-to-date items from display."
>> +  (interactive)
>> +  (vc-dir-hide-some-states '("up-to-date")))
>  
> Why bother?
>
>
>         Stefan

This bug report was last modified 12 years and 280 days ago.

Previous Next


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