On 9 November 2016 at 19:36, Eli Zaretskii <eliz@gnu.org> wrote:
> From: Reuben Thomas <rrt@sc3d.org>
> Date: Tue, 8 Nov 2016 22:16:45 +0000
> Cc: 18716@debbugs.gnu.org
>
>  I don't understand what happened to the comment about *.JPG files on
>  case-sensitive filesystems,
>
> I took it into account. My experience is that on a case-insensitive system (e.g. a GNU system), one finds
> occasional files like this, typically copied from other systems or extracted from archives. These are not a
> problem for dired-omit-mode. For visiting such files, treating auto-mode-alist and similar case-insensitively is
> no problem.

Sorry, I don't understand what you mean by "these are not a problem".
With your change, *.JPG files will no longer be treated like *.jpg on
Posix systems.  Won't people who want *.JPG hidden complain?  IOW,
isn't this change backward-incompatible?

​I'm confused. I have not changed the behaviour of visiting files. When I said "treating auto-mode-alist and similar case-insensitively is not a problem", I meant that it is OK that auto-mode-alist is applied case-insensitively.

When we talk about *.JPG files, we are not talking about dired-omit-mode, because ".jpg" is not a suffix that would (normally) be omitted.​

What I was trying to explain is that unexpected case-insensitivity in auto-mode-alist is not a problem, because the user immediately sees the effects. On the other hand, in dired-omit-mode it is a problem, because the user might not see the effects (the effects are to hide things).

I double-checked, and the code I changed, dired-mark-unmarked-files, is only called by dired-omit. However, it can also be called interactively, so I have certainly changed the interactive behavior.

I could add a parameter to dired-mark-unmarked-files, case-fold-p, defaulting to nil, which would be set by its current callers. But I think you are saying that this change to the behavior of dired-omit-mode, which I have suggested does not need a new preference, should indeed have a new preference, so I can add that too. I think, though, that it should default to `t', i.e. dired-omit-mode behaving case-sensitively by default.

If you'd say what you consider acceptable, I'll implement it.
 
> +            (case-fold-search (memq system-type '(windows-nt cygwin))))

The list should include ms-dos as well.

​OK, I will add a patch for files.el, since I got the list from there, where it is used for the same purpose.​ Or perhaps there should be a global variable defined in files.el containing the list?

> * lisp/dired-x.el (Commentary): Remove USAGE section explaining how to
> use dired-x from .emacs.  It is now fully customizable.
> * lisp/dired-x.el (dired-guess-shell-alist-user): Remove explanation of
> how to set this custom variable in .emacs.  It should be customized.

Why remove these comments?  The existence of Custom doesn't preclude
people from customizations in plain Lisp.

The documentation is a maintenance burden (since it is hand-written and duplicate), few people will read it anyway, and further it is redundant, since it can be customized in plain Lisp in the same way as any other defcustom. (I presume you're not implying that we should add documentation to every Lisp source file to show how to customize each defcustom?) Further, the documentation as it is implies that these variables *should* be customized in plain Lisp, since (unlike most cases), there is explicit documentation about it.

--