[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#63648: 29.0.90; project.el: with switch-use-entire-map, switch-proje
From: |
Juri Linkov |
Subject: |
bug#63648: 29.0.90; project.el: with switch-use-entire-map, switch-project errors on non-project commands |
Date: |
Fri, 02 Jun 2023 09:46:25 +0300 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/30.0.50 (x86_64-pc-linux-gnu) |
>>>>>>> (Tangential further thought: I wonder if we could make C-x p work
>>>>>>> as a prefix for all commands automatically, so for example
>>>>>>> C-x p C-x C-j would open the project root,
>>
>> I just noticed that 'C-x p C-x C-j' would open the parent directory
>> of the project root, not the root itself, since 'C-x C-j' in the root
>> jumps to its parent.
>
> Only in dired buffers. If not in dired, and not in a file-visiting
> buffer, it just goes to default-directory.
You are right, I tried with the next-default-directory patch,
and it works like you described.
> That is kind of annoying for making C-x p p C-x C-j go to the root,
> though, because its behavior will depend on the current buffer... Maybe
> C-x p p can switch buffers before running the command?
Alas, can't switch buffers because such commands as 'C-x p g'
read the default value from the current buffer.
> Or maybe we can just change how C-x C-j behaves so it works
> intuitively with C-x p p?
The problem is in 'C-x C-j'. In dired buffers it uses the value of
'dired-subdir-alist' instead of 'default-directory', so the patch with
'next-default-directory' doesn't help.
- bug#63648: 29.0.90; project.el: with switch-use-entire-map, switch-project errors on non-project commands, (continued)
bug#63648: 29.0.90; project.el: with switch-use-entire-map, switch-project errors on non-project commands, Stefan Monnier, 2023/06/02
bug#63648: 29.0.90; project.el: with switch-use-entire-map, switch-project errors on non-project commands, Spencer Baugh, 2023/06/01