Subject: Re: bug#72272: [PATCH] dired-hide-details-mode hides directory's absolute path

From: Andrea Corallo <[email-masked]>
Date: Mon, 05 Aug 2024 05:45:29 -0400

Eli Zaretskii <[email-masked]> writes:

>> From: Alvaro Ramirez <[email-masked]>
>> Date: Wed, 24 Jul 2024 12:17:58 +0100
>> 
>> Hi folks,
>> 
>> Sending an initial patch. Happy to iterate on it, add tests, 
>> etc. if we
>> reckon the feature is worth pursuing.
>> 
>> Set `dired-hide-details-hide-absolute-location` to non-nil and 
>> toggle
>> `dired-hide-details-mode` to hide the current directory's absolute 
>> path.
>> 
>> This is my first submission, might need some process guidance.
>
> Thanks.
>
> Stefan and Andrea, any comments?
>
> I have a few minor ones:
>
>> From: xenodium <[email-masked]>
>> Date: Tue, 23 Jul 2024 21:55:37 +0100
>> Subject: [PATCH] Hides current location's path via dired-hide-details-mode
>                                             ^^^^
> Please don't use "path" for anything except PATH-style directory
> lists.  The GNU Coding Standards frown on such usage.
>
>> +(defcustom dired-hide-details-hide-absolute-location t
>> +  "Non-nil means `dired-hide-details-mode' hides current location's absolute path."
>
> Same here.
>
>> +            (if-let ((dir-base (file-name-nondirectory new-dir-name))
>> +                     (dir-path (file-name-directory new-dir-name))
>> +                     (hide-dir-path (and dired-hide-details-hide-absolute-location
>
> And here.
>
> Also, this change needs a NEWS entry.

No further comments other than:

> @@ -3268,6 +3275,11 @@ dired-hide-details-update-invisibility-spec
>  	       'add-to-invisibility-spec
>  	     'remove-from-invisibility-spec)
>  	   'dired-hide-details-information)
> +  (funcall (if (and dired-hide-details-mode
> +		    dired-hide-details-hide-absolute-location)
> +	       'add-to-invisibility-spec
> +	     'remove-from-invisibility-spec)
> +	   'dired-hide-details-absolute-location)

don't we favor #' in place of ' when quoting functions?

Thanks

  Andrea