On Tue, Mar 22, 2016 at 11:12:27PM +0100, Liviu Andronic wrote: > On Tue, Mar 22, 2016 at 10:59 PM, Scott Kostyshak <skost...@lyx.org> wrote: > > On Tue, Mar 22, 2016 at 09:46:14PM +0100, Liviu Andronic wrote: > >> Dear all, > >> With the pre-releases I sometimes (very rarely) notice a strange > >> behavior, whereas LyX saves a document like: filename-412.lyx > >> > >> The numbers are always random, three digits. The strangely-named files > >> appear in the same dir as the original filename.lyx file. I never know > >> how to replicate this, nor if it's an issue (e.g. some stray backup > >> being created by LyX). > >> > >> Has anyone else noticed something like this? > > > > Yes, this happens when you open and save a file that had a previous file > > format. This way, if lyx2lyx causes data loss and you save your file, > > you can still recover the original file. > > > > It is a new feature in 2.2.0. > > > Oh, nice feature. Perhaps we should display a quick pop-up telling the > user this happened? I mean, this probably happens rarely enough, and > otherwise the user may end up none the wiser (like I did) finding a > strangely-named file in the working directory.
Perhaps, I'm not sure. Let's see what others think. I'm worried about confusing the user even more, who might not even understand (or need to understand) anything about file formats. > Also, do we mention this in About > Release notes? I couldn't spot any > reference to this... Good idea. What do you think of the attached patch? Scott
From 3ada5d5265ee17d5cfc3939e8d5252a9acfdd917 Mon Sep 17 00:00:00 2001 From: Scott Kostyshak <skost...@lyx.org> Date: Sat, 26 Mar 2016 22:32:53 -0400 Subject: [PATCH] RELEASE-NOTES: document creation of backup file We now create a backup file when overwriting a file with a new file format. See #9554 and cc83dfa8. This is now documented in RELEASE-NOTES. Thanks to Livu. --- lib/RELEASE-NOTES | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/lib/RELEASE-NOTES b/lib/RELEASE-NOTES index 3812ff8..1f5a2be 100644 --- a/lib/RELEASE-NOTES +++ b/lib/RELEASE-NOTES @@ -154,3 +154,13 @@ package option "Automatic" is selected. In order to use babel, select "Always babel" instead. This may be needed if a document uses code that is specific to babel. + +* As usual, when opening and saving a document that was created by a previous + major version of LyX (in this case 2.1.x), the file format is changed to + the new file format (in this case 2.2.x). What is different starting with + 2.2.0 is that when we save a file that was not originally in the current LyX + format, we create a backup of the original file. We put it in the backup + directory, if one exists, otherwise in the directory the original file is + in. This is the same strategy as for normal backups. This backup file can be + helpful in case a bug in lyx2lyx caused data loss. For more information, see + #9554. -- 2.1.4
signature.asc
Description: PGP signature