GNU bug report logs -
#40325
make backup files for "-i" option invisible
Previous Next
Full log
View this message in rfc822 format
On Mon, Mar 30, 2020 at 10:21 PM Assaf Gordon <assafgordon <at> gmail.com> wrote:
> Hello,
>
> On 2020-03-28 10:00 a.m., nokangaroo wrote:
> > The visible backup files create problems with file managers, e. g. they show up
> > in MATE, and I have to reload the folder to make them disappear. The following
> > patch creates invisible files:
>
> Nice idea, and doesn't seem to cause any regressions.
> If there are no objects (Jim?), I'll push this soon in your name.
> The patch is small enough that copyright assignment is not necessary.
>
> > BTW why not use /tmp instead of '.'?
>
> When using "-i/--in-place", the new content is first written
> to the temporary file, and then a rename(2) sys-call is used to replace
> the input file with the new file.
>
> When the two files are in the same directory,
> such rename(2) sys-call is atomic and quick.
>
> On many systems the "/tmp" directory is mounted
> on a different file system (or in memory),
> and we'd have to use a non-atomic and slower "copy+delete" instead of
> a rename(2).
Thank you both!
Perhaps s/invisible/hidden/ in the commit log. Also, Assaf, would you
please add a NEWS entry, since this is a user-visible change?
Thanks,
Jim
This bug report was last modified 5 years and 73 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.