[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: renaming current file and buffer
From: |
Dieter Wilhelm |
Subject: |
Re: renaming current file and buffer |
Date: |
Wed, 04 Jan 2006 00:51:25 +0100 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
Peter Dyballa <Peter_Dyballa@Web.DE> writes:
> Am 03.01.2006 um 11:16 schrieb Dieter Wilhelm:
>
>>> Doesn't C-x C-w (`write-file') work for you?
>>
>> Agreed, write-file gives me the opportunity for choosing another name
>> (with the corresponding buffer name). But then I'd have to kill
>> the badly
>> named file in a second step (e.g. in a dired buffer) since the old,
>> now redundant file remains on the file system.
>
> I now remember how I handle this: I rename in dired-mode the file I
> am editing (having it saved before). The buffer name follows this
> change after some time.
Knowing the behaviour of `rename-file' (not changing the buffer name)
I was somehow prejudiced against testing this possibility with
dired. But it actually works, thanks a lot for this hint!
With the standard dired it's a tad slow albeit. It means getting into
dired (C-x 4 d, lest I don't forget the filename), then looking for
the file (possibly searching with C-s). This might, just might
justify the hassle of using a home-made function. But with the
dired-x package - I just discovered - its working like a charm. Just
typing C-x C-j in the respective buffer is getting one into a dired
buffer with point already at the corresponding file! Then R NEW-NAME
RET RET and here we are again.
Great stuff
--
Best wishes
Dieter Wilhelm
- renaming current file and buffer, Dieter Wilhelm, 2006/01/02
- Re: renaming current file and buffer, Ian Zimmerman, 2006/01/02
- Re: renaming current file and buffer, Dieter Wilhelm, 2006/01/03
- Re: renaming current file and buffer, Peter Dyballa, 2006/01/03
- Re: renaming current file and buffer,
Dieter Wilhelm <=
- Re: renaming current file and buffer, Peter Dyballa, 2006/01/03
- Re: renaming current file and buffer, Dieter Wilhelm, 2006/01/03
- Re: renaming current file and buffer, Peter Dyballa, 2006/01/04
- Message not available
- Re: renaming current file and buffer, David Combs, 2006/01/31
- Re: renaming current file and buffer, Ian Zimmerman, 2006/01/03