epithet icon indicating copy to clipboard operation
epithet copied to clipboard

`epithet-rename-buffer` causes `eww` to create multiple buffers of the same site

Open duckwork opened this issue 4 years ago • 0 comments

The problem:

If I open the same link with eww twice, it opens two buffers to the same site. I.e., *eww*<https://example.com>, *eww*<https://example.com><2>, and so on.

Thoughts:

I'm not totally sure how to fix this; the eww function itself is what causes this problem:

(pop-to-buffer-same-window
   (cond
    ((eq arg 4)
     (generate-new-buffer "*eww*"))
    ((eq major-mode 'eww-mode)
     (current-buffer))
    (t
     (get-buffer-create "*eww*"))))

I'm creating this issue to bring it to your attention, I guess? As far as I can think, the way to fix it would be to redefine eww to look for other buffers with the same URL, or delete duplicates after they're made and switch to the “real” buffer. Of course, neither of those are … great ideas. I'm open to others!

duckwork avatar Aug 29 '21 14:08 duckwork