Subject: bug#35564: [PATCH v5] Tweak dired warning about "wildcard" characters

From: Kévin Le Gouguec <[email-masked]>
Date: Mon, 04 Nov 2019 07:36:53 +0100

Juri Linkov <[email-masked]> writes:

>> '?' would be more preferable since this is the standard way to ask
>> for additional information in Dired, for example, on error it shows:
>>
>>   Dired error--type ? for details
>>
>> where '?' shows the details.  dired-do-shell-command should do the same
>> in its prompt.  read-multiple-choice could be changed to not add
>> its own help option when a '?' is provided in its 'choices' arg.
>
> I meant using the same logic as in 'read-answer':
>
>           (if (assoc "help" answers)
>               answers
>             (append answers '(("help" ?? "show this help message"))))
>
> i.e. if '?' is provided in the function argument then use it,
> otherwise use the default value.

I'd like to keep read-multiple-choice's built-in help action available
though, I find it quite ergonomic.  Plus, the fact that it is bound to ?
and C-h makes it consistent with help-for-help, another command whose
purpose is to describe prompt bindings in more details.

Here are the ways forward I can see:

1. keep 'd' for "details" (a la nsm.el),

2. use 'h' for "help": more intuitive for "what the ftok is going on"
   reactions, though perhaps confusing when shown alongside '?',

3. teach read-multiple-choice to let go of '?', and…

    3.1. that's it; give up on the bindings-explaining help buffer,

    3.2. move the code generating this buffer to an external function,
         which callers could re-use to fill in their own help buffer,

4. add a third, optional argument to read-multiple-choice
   (e.g. help-text) that would be added to the help buffer
   (e.g. squeezed between the prompt and the bindings).

Ranked according to my preference:

1. (keeping "help" mnemonics (?, C-h) for "what can I do" actions, and
   "details/description/debug" mnemonics for "give more context"
   actions)

4. (reduces the number of actions for this specific prompt)

3.2. (same, only more involved)

3.1. (sad to give up on the bindings description)

2. (see rationale for 1; plus 'h' and '?' doing different things might
   be confusing)

Tell me if there are other solutions I missed, or if you find any of
these satisfying!

Thank you for your time, and for the review.