[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Emacs-diffs] master e0ee41d: Allow customizing the display of proje
From: |
Basil L. Contovounesios |
Subject: |
Re: [Emacs-diffs] master e0ee41d: Allow customizing the display of project file names when reading |
Date: |
Thu, 16 May 2019 10:51:27 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) |
"Basil L. Contovounesios" <address@hidden> writes:
> Dmitry Gutov <address@hidden> writes:
>
>> On 15.05.2019 20:46, Basil L. Contovounesios wrote:
>>> Sorry if this has been discussed before, and maybe it's just me, but I
>>> don't think it makes sense to offer internal double hyphen functions as
>>> alternatives for a user option, let alone to point the user to such an
>>> internal function which lacks a docstring, "for the argument list".
>>
>> No, we never discussed this in particular. So I pushed the cleanest version
>> that
>> made sense to me.
>
> I'm grateful for the addition, but I think user options ought to also
> make sense to the user.
>
>> Do we not do that (put internal functions as possible values of a user
>> option)?
>
> Sorry, the emphasis in my last message was meant to be on the lack of
> any description of the user option's arglist. If the defcustom is to
> refer the user elsewhere, that place might at least have a docstring.
I think even something as simple as the following would help:
diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el
index eab508af3a..cc45a71f57 100644
--- a/lisp/progmodes/project.el
+++ b/lisp/progmodes/project.el
@@ -477,6 +477,10 @@ project-read-file-name-function
(defun project--read-file-cpd-relative (prompt
all-files &optional predicate
hist default)
+ "Read a file name, prompting with PROMPT.
+ALL-FILES is a list of possible file name completions.
+PREDICATE, HIST, and DEFAULT have the same meaning as in
+`completing-read'."
(let* ((common-parent-directory
(let ((common-prefix (try-completion "" all-files)))
(if (> (length common-prefix) 0)
Thanks,
--
Basil
Re: [Emacs-diffs] master e0ee41d: Allow customizing the display of project file names when reading, Stefan Monnier, 2019/05/15