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

From: Eli Zaretskii <[email-masked]>
Date: Fri, 02 Dec 2022 10:08:42 +0200

> Cc: [email-masked]
> Date: Fri, 02 Dec 2022 03:34:30 +0000
> From: Randy Taylor <[email-masked]>
> 
> 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?

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.