bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#59756: [PATCH] Use file-name-nondirectory to determine project-name


From: Stefan Kangas
Subject: bug#59756: [PATCH] Use file-name-nondirectory to determine project-name
Date: Fri, 2 Dec 2022 04:47:35 -0800

Eli Zaretskii <eliz@gnu.org> writes:

>> If a project is named something like ".emacs.d", file-name-base will
>> return ".emacs" instead of ".emacs.d" as expected (or at least as I
>> expect it).
>>
>> Therefore, we use file-name-nondirectory instead.
>
> Why do we want to support such project names?

Because people put their configuration files under version control, and
they want to use project commands there.  For example "~/.emacs.d",
which is what I use.

> I could also name my project /foo/bar/baz, and defeat file-name-nondirectory
> as well.  Where does it end?
>
> My suggestion is to require that project names don't include slashes,
> backslashes, periods and maybe also colon characters.

It's fine to disallow slashes, backslashes, and colons, but banning
periods would break some of my most important use-cases.  So I hope we
won't do that.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]