GNU bug report logs - #36122
A second find-dired clobbers the first's buffer

Previous Next

Package: emacs;

Reported by: 積丹尼 Dan Jacobson <jidanni <at> jidanni.org>

Date: Fri, 7 Jun 2019 00:44:02 UTC

Severity: wishlist

Tags: wontfix

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


Message #15 received at 36122 <at> debbugs.gnu.org (full text, mbox):

From: Juri Linkov <juri <at> linkov.net>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: 36122 <at> debbugs.gnu.org,
 積丹尼 Dan Jacobson <jidanni <at> jidanni.org>
Subject: Re: bug#36122: A second find-dired clobbers the first's buffer
Date: Tue, 09 Jul 2019 23:18:22 +0300
>> Do find-dired on directory A.
>> Then do find-dired on directory B.
>> A second find-dired clobbers the first's buffer!
>> Imagine if there could only be one Dired buffer in emacs.
>> Well, the same goes for find-dired.
>
> That's how the kinda related commands like M-x grep work -- if you want
> more than one, you have to rename them.  So I think this works as
> advertised.

Yes, there are many ways to do this:

(add-hook 'dired-after-readin-hook 'rename-uniquely)

(add-hook 'compilation-mode-hook 'rename-uniquely)

or better

(setq compilation-buffer-name-function
      (lambda (mode-name)
        (generate-new-buffer-name
         (concat "*" (downcase mode-name) "*"))))
...




This bug report was last modified 5 years and 320 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.