backup file?
Brought to you by:
tringali
when I use nedit to edit my souce code, e.g. a file
named "aa.c", sometimes it creates a permanent file
named "~aa.c" on my disk.
I can't tell how to depulicate this.
-----------------------------------------------------------
NEdit 5.5RC1
Jul 7, 2004
Built on: Linux, 386, Intel C++
Built at: Jul 9 2004, 09:32:45
With Motif: 2.2.3 [@(#)Motif Version 2.2.3] (UNTESTED)
Running Motif: 2.2 [unknown]
Server: The XFree86 Project, Inc 40300000
Visual: 24-bit TrueColor (ID 0x21, Default)
Locale: en_US.iso885915
-----------------------------------------------------------
Logged In: YES
user_id=119143
Is ~aa.c still there if aa.c is saved? If you quit NEdit?
If not then this is a feature, a backup as you have guessed.
You can switch it off in the preference menu.
Logged In: YES
user_id=121553
Specifically, that's the "Incremental Backup." It should only be there
when a) NEdit is open and you have made unsaved changes to the file,
or b) NEdit has crashed or been killed while unsaved changes existed.
If it's there in any other circumstances then it's a bug.
Logged In: NO
In most cases, I could see the ~ file when I made unsaved
changes to the file, and it dispeard after I saved the file. But
sometime (very rarely) I could see the ~file even after I
saved the file and quit nedit (I mean I didn't kill nedit and
nedit didn't crash).
Because most of my file were saved on a remote disk so I
wonder this might be related with, for example, the disk was
not available for a very short time....
Logged In: YES
user_id=73597
I see that too, very occasionally, but I've never been able
to reproduce it either.
It used to happen more often with older versions, but most
of the cases were fixed. There must be at least one scenario
in which it still happens, though.
Logged In: NO
I have the opposite problem - I can't switch it *on*. nedit
doesn't seem to create the incremental backups at all. With
ls and a couple of file managers and a modified file in
nedit, I see no ~file and I tested a modification, killing
the window after 80 seconds and there was no ~file and the
modification was lost. I've diffed my backup of nedit.rc
from 5.4 and see no change with the current in that regard.
I toggled the setting on and off and subsequent diffs show
it being recorded properly in the rcfile. However, it
doesn't seem to create the file.
Slackware 10, ReiserFS
NEdit 5.5RC1
Jul 23, 2004
Built on: Linux, 386, GNU C
Built at: Jul 24 2004, 13:45:55
With Motif: 2.1.30 [@(#)Motif Version 2.1.30]
Running Motif: 2.1 [unknown]
Server: The X.Org Foundation 60700000
Visual: 24-bit TrueColor (ID 0x21, Default)
Locale: en_US
Logged In: NO
I'm an idiot. Never mind. The incremental backups are being
created.
Logged In: YES
user_id=73597
I have found a scenario that leaves behind an incremental
backup file: make a number of changes till a backup file
appears; save the file (the backup file disappears); undo
the changes (the backup file re-appears); redo the changes
up to the point where the file was saved; close the file.
The backup file is not removed when the saved state is
reached through a series of redo operations (it works fine
for undo, though).
I have fixed this in CVS (too late for 5.5).
I'm pretty confident that there are no more cases left in
which the backup file is left behind (except for a kill or
crash).