GNU bug report logs - #12507
24.2.50; `bookmark-write-file': use `write-file', not `write-region', to get backups

Previous Next

Package: emacs;

Reported by: "Drew Adams" <drew.adams <at> oracle.com>

Date: Mon, 24 Sep 2012 18:44:01 UTC

Severity: wishlist

Tags: notabug

Found in version 24.2.50

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


Message #129 received at 12507 <at> debbugs.gnu.org (full text, mbox):

From: Drew Adams <drew.adams <at> oracle.com>
To: Lars Ingebrigtsen <larsi <at> gnus.org>, Chong Yidong <cyd <at> gnu.org>
Cc: Karl Fogel <kfogel <at> red-bean.com>, 12507 <at> debbugs.gnu.org
Subject: RE: bug#12507: [debbugs-tracker] Processed: severity 12507 wishlist
Date: Fri, 18 Sep 2020 16:23:43 +0000 (UTC)
> >> Am I wrong that `write-region' does not provide for backups?
> >> If not, then this is clearly a bug, and a pretty serious one, IMO.
> >
> > It would be annoying litter the filesystem with backups for every
> > internal configuration file.  The abbrev file and desktop file are not
> > backed up either, and I think that's fine.
> >
> > I wouldn't mind adding a global feature to optionally enable backups for
> > such files.
> 
> Indeed; data files are normally not backed up, and the bookmark file is
> one such file.  So I'm closing this bug report.
> 
> If somebody wants a global "make write-region make backup files"
> (possibly on a per-mode basis?), then a new bug report should be opened.

No, `write-region' should not, itself, make a backup file.

It's not blanket either-everything-or-nothing.  Some
"data" files deserve backup; some don't.

A bookmark file definitely does deserve it.  It's
typically updated frequently (each time a bookmark
is visited).

Emacs goes out of its way to protect user data.  Why
now we would think that only "code" or non-"data"
files deserve backing up, I can't imagine.

Some "data" files are quite important.  A bookmark
file is one such.  `bookmark-write-file' should
use `write-file', not `write-region'.  I made that
change in Bookmark+ 8 years ago.




This bug report was last modified 4 years and 176 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.