bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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


From: Jambunathan K
Subject: bug#12159: 24.1.50; vc-dir: Need a way to hide unregistered files
Date: Mon, 13 Aug 2012 23:16:23 +0530
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1.50 (gnu/linux)

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 :-).

Attachment: bug#12159-approach-1.patch
Description: approach-1.patch

Attachment: bug#12159-approach-2.patch
Description: approach-2.patch

>> +    * 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

reply via email to

[Prev in Thread] Current Thread [Next in Thread]