GNU bug report logs -
#57816
28.2; Renaming a help buffer from help-mode-hook
Previous Next
Reported by: Damien Cassou <damien <at> cassou.me>
Date: Thu, 15 Sep 2022 04:44:01 UTC
Severity: normal
Found in version 28.2
Fixed in version 29.1
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
Damien Cassou <damien <at> cassou.me> writes:
> In GNU Emacs 28.2, I would like to automatically rename help buffers so
> their name reflect their content. For example, I want *Help: car*
> instead of just *Help* for the help buffer of `car'. Unfortunately,
> adding #'rename-buffer to `help-mode-hook' doesn't work as this results
> in 2 buffers instead of just one:
>
> emacs --batch -Q \
> --eval "(add-hook 'help-mode-hook (lambda () (rename-buffer \"*foo*\")))" \
> --eval "(describe-function #'describe-function)" \
> --eval "(prin1 (cons (get-buffer \"*Help*\") (get-buffer \"*foo*\")))"
>
> prints
>
> (#<buffer *Help*> . #<buffer *foo*>)
>
> After the "rename", there is still a buffer with the old name. Is there
> a more correct way to do this?
I can reproduce this in Emacs 28.2, but not in Emacs 29, so it looks
like this has been fixed already.
This bug report was last modified 2 years and 301 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.