On 1/10/2018 2:05 p.m., Richard Kimberly Heck wrote:
We use 'versioned' user directories on OSX and Windows: By default, the
major version number is used as part of the directory name. This leads,
on Windows, to hassles for users: When you upgrade from 2.2 to 2.3, you
have to manually copy the old user directory to the new location if you
want to preserve your preferences, etc.
I've more or less got a patch for configure.py that mimics what already
happens on OSX on Windows, but now I've started to wonder about it. The
logic behind the patch is this.
(1) When we configure, we first make sure we are in the 'default' user
directory, by checking the pathname. If not, we do nothing special.
(2) Next, we look for lyxrc.defaults. If it's there, we rightly figure
it's not a new directory that we're creating but we're just
reconfiguring, and so we do nothing special.
(3) Next, we look for previous user directories LyX2.2, LyX2.1, etc. If
one is found, we copy its contents into the current directory
But what if the user has purposely deleted their user directory so as to
get a fresh one? Then, when they restart, if we find an old one, we copy
its contents again. But what if there was some problem with the old
preferences? Something seems wrong about this to me.
I have had this problem. Rather than deleting the directory I rename it.
LyX then creates a new one to which I can copy contents across item by
item from the renamed directory, since there is usually only one thing
causing the problem, testing LyX as I go until the offending item shows up.
I wonder if, all things considered, a better option would be to stop
using versioned user directories on Windows, at least. Then no special
copying is needed, etc. If we did this for 2.4, then we could tell
people *as usual* that they needed to copy over their old preferences,
but that would be the last time.
I take it that the reason to have versioned user directories is so
people can have parallel installations of 2.2 and 2.3, say. But you can
still do that, of course, by manually setting the user directory. How
many people do that anyway on Windows?
I have 2.2 and 2.3 installed in parallel like this but I don't know
how to manually set the user directory. I just uninstalled & reinstalled
LyX to see if I had overlooked an option to do this during the
installation process but no, and there's nothing obvious to me under
Tools > Preferences > Paths. If manual naming of the user directory is
available then your suggestion makes sense.
Andrew
Riki
---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus