|
From: | Dmitry Gutov |
Subject: | Re: Name of buffers created by project-shell |
Date: | Sun, 21 Mar 2021 21:44:19 +0200 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 |
On 15.03.2021 02:41, Dmitry Gutov wrote:
I think there's a problem even without using C-u: `project-shell' from a buffer whose associated project root path is /src/project1 creates a buffer named *shell*. Then `project-shell' from a buffer whose associated project root path is /src/project2 creates a buffer named *shell*<project2> (I am using the default `post-forward-angle-brackets' for `uniquify-buffer-name-style'). But the uniquify rationalize mecanism doesn't rename the first buffer to *shell*<project1> which happens to be the case for buffers visiting files...Yup, that's another bug. It should also how up for vc-dir buffers too.
Actually, it didn't occur for vc-dir buffers. So it's arguably a bug in my code.
Attaching the updated patch which fixes that particular problem, though I'm a little more suspicious of some of uniquify's choices now.
In particular, this code depends on list-buffers-directory being set to a value in particular format which is very non-obvious from this variable's docstring.
And to have uniquify work similarly with buffers created by M-x shell and M-x eshell as well, these commands need similar changes (we can't really depend on them in project.el because it's an ELPA Core package), as well as shell-mode and eshell-mode being listed in uniquify-list-buffers-directory-modes.
uniquify-project-shell.diff
Description: Text Data
[Prev in Thread] | Current Thread | [Next in Thread] |