bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

correct name for new buffer of same file


From: Dan Jacobson
Subject: correct name for new buffer of same file
Date: 23 May 2001 15:21:58 +0800
User-agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7

You write a buffer to the file of another buffer and:

        A buffer is visiting /home/jidanni/my_internal_links; proceed? 
        Wrote /home/jidanni/my_internal_links

perhaps you do this several times.  Before long you will have

    my_internal_links<3>  10890 Compilation /home/jidanni/my_internal_links
    my_internal_links<2>  10544 Compilation /home/jidanni/my_internal_links

etc. etc. in the buffer list.  Nothing bad do far.  Well, there you
are viewing what you thought was that file and you make a little
adjustment and

        my_internal_links changed on disk; really edit the buffer? (y, n, r or 
C-h) 
        Please type y, n or r; or ? for help

Only now emacs tells me!  I've been looking at that file for a half an
hour already and only now does emacs tell me it is an old version.  If
I hadn't happened to start to edit it I would have never known.

The problem is that emacs gets cluttered with look alike buffers with
look alike names in the above incident.  Your good intentions of
preventing user accidental buffer loss this way have already bitten me
several times.  OK, how about calling the old buffers "*OLD
filename.txt*"<2>...

As proof positive let me ask, for files on disk, does the original
version keep the same name while the newer versions have ~1~ ~2~ ~3~
appended?  No.  So why for buffer names do that (with <2> <3> ...)?
OK, never mind why. Just do something else... [best to keep only one
buffer, I mean emacs already asked me if I knew what I was doing.  [The
old way could become an option.]]

The current version of my file I want in buffer "file", not "file<2>".
And you had better prepend "*OLD " or else one is surely bound to
switch to it in mistake even with the right number at back.
-- 
http://www.geocities.com/jidanni Tel886-4-25854780 e-mail:restore .com.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]