From: Juri Linkov <juri@linkov.net>
To: Dmitry Gutov <dmitry@gutov.dev>
Cc: 70996@debbugs.gnu.org
Subject: bug#70996: project-find-file defaults
Date: Sun, 09 Jun 2024 19:51:17 +0300 [thread overview]
Message-ID: <86cyoqjdcq.fsf@mail.linkov.net> (raw)
In-Reply-To: <abb9088a-875c-451a-ad19-e4a2d3ad6fec@gutov.dev> (Dmitry Gutov's message of "Sat, 8 Jun 2024 03:28:48 +0300")
>> But the problem is that in this case it drops the current file name
>> as the default value that is also useful in many cases.
>> Fortunately, the minibuffer supports a list of default values,
>> like in the following patch:
>
> This seems like a good idea, except it reverses the priority: previously,
> if file-at-point was present, it would be the default, not the current file
> name.
I mentioned in the log message that this change was intentional.
> So how about this?
The reason of this change to make the first item of the M-n list
more deterministic:
1. when there is no thing-at-point, then the first item will be
buffer-file-name;
2. and also when there is a thing-at-point, the first item
will remain buffer-file-name.
Otherwise, it was too unpredictable: after typing 'M-n RET'
to use buffer-file-name, it often did a wrong thing
when point happened to stay in a thing-at-point.
next prev parent reply other threads:[~2024-06-09 16:51 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-17 6:36 bug#70996: project-find-file defaults Juri Linkov
2024-05-28 16:32 ` Juri Linkov
2024-06-08 0:28 ` Dmitry Gutov
2024-06-09 16:51 ` Juri Linkov [this message]
2024-06-11 0:02 ` Dmitry Gutov
2024-06-11 16:58 ` Juri Linkov
2024-06-11 20:04 ` Dmitry Gutov
2024-06-12 0:11 ` Spencer Baugh
2024-06-12 13:52 ` Dmitry Gutov
2024-06-12 20:04 ` Dmitry Gutov
2024-06-14 17:00 ` Juri Linkov
2024-06-14 17:24 ` Dmitry Gutov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=86cyoqjdcq.fsf@mail.linkov.net \
--to=juri@linkov.net \
--cc=70996@debbugs.gnu.org \
--cc=dmitry@gutov.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.