all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Uwe Brauer <oub@mat.ucm.es>
To: emacs-devel@gnu.org
Subject: Re: rename buffer but overwrite already existing one
Date: Mon, 23 Mar 2020 20:24:56 +0100	[thread overview]
Message-ID: <87sghy98mv.fsf@mat.ucm.es> (raw)
In-Reply-To: jwvk13baqg2.fsf-monnier+emacs@gnu.org

[-- Attachment #1: Type: text/plain, Size: 1232 bytes --]

>>> "SM" == Stefan Monnier <monnier@iro.umontreal.ca> writes:

   >> Couldn't rename-buffer, optionally, overwrite the content of a buffer.
   > Yes and no: it depends on what you mean by "overwrite the content of a buffer".

   > Here's what I think could be done easily:

   > - say you have buffers "mybuf" "otherbuf"
   > - you're in "mybuf" and you do `M-x rename-buffer RET otherbuf RET`.
   > - Emacs currently refuses it but it could accept your command by
   >   first renaming "otherbuf" to "otherbuf<1>", or by 
   >   killing "otherbuf",
^^^^^^^^^^^^^^^^^^^^^^^^^^
this is what I would prefer! Kill it.

   >   or by asking you for a new name to use for that other buffer.

   > But the two buffers can be unified into a single one.

   > Of course, another option might be to tweak `rename-uniquely` so it
   > automatically chooses a more informative name than what you get by
   > adding a "<N>".  I think such a feature might be a good idea
   > in general.  E.g. we could add a variable `buffer-name-suffix-function`
   > which some major modes could set to provide "meaningful" unique names.

Yeah, but I tend to loose the track easily of these buffers. 



   >         Stefan




[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 5673 bytes --]

  reply	other threads:[~2020-03-23 19:24 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-23 18:05 rename buffer but overwrite already existing one Uwe Brauer
2020-03-23 18:23 ` Stefan Monnier
2020-03-23 19:24   ` Uwe Brauer [this message]
2020-03-23 19:18 ` Eli Zaretskii
2020-03-23 19:23   ` Uwe Brauer
2020-03-23 19:35     ` Eli Zaretskii
2020-03-23 19:46       ` Uwe Brauer
2020-03-23 19:41     ` Andreas Schwab
2020-03-23 19:43       ` Uwe Brauer
2020-03-23 20:02         ` Stephen Berman
2020-03-23 20:49           ` Uwe Brauer
2020-03-23 21:21             ` Stephen Berman
2020-03-24  9:17               ` Uwe Brauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87sghy98mv.fsf@mat.ucm.es \
    --to=oub@mat.ucm.es \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.