[Libreoffice] LibreOffice config migration

Michael Meeks michael.meeks at novell.com
Fri Oct 29 10:04:31 PDT 2010

Hi guys,

On Fri, 2010-10-15 at 19:23 +0200, André Schnabel wrote:
> (no question on 1. - harden the code for migration)

	Speaking of which - I notice that neither us, nor up-stream register
the migrationoo3.uno.so - so the "migrate from 3.x" code is never
executed :-) we only migrate from 2.x - any ideas why that is ?
(Thorsten?). I will push a fix to enable that in scp2 over the weekend -
scream if that will bite ;-) [ it works for me ].

> ...
> > 	2. we continue to do automatic config migration since this is
> > 	   a commonly desired use-case
> > 	*but*
> > 	   as we migrate the settings the first time, we write into the
> > 	   (original - ie. the old version)'s directory a stamp file
> > 	   that says "these have been imported"
> > 	*and*
> > 	   if the same version is run again with the new settings
> > 	   directory removed (ie. someting went wrong); we prompt the
> > 	   user on the second time:
> > 		"do you want to (re-)import settings from ABC install"

	So - I'm hacking this up. Interestingly, it seems to me that; after a
migration - we hit an aspirational code-path:

    if ( bRestartRequested )
        // wouldn't the solution be more clean if SalMain returns the exit code to the system?
        _exit( ExitHelper::E_NORMAL_RESTART );

	Not had a chance to dig out quite why that is yet.

	I was wondering though - does the Mac stuff work nicely ? or do we end
up in infinite re-starting loops sometimes ? either way the code looks
fairly generic & re-usable for Unix generally, so I'm tempted to add
that - so we would just get a clean re-start after migration (or SEGV).

	I (somehow) seem to remember OO.o re-starting itself sometime in the
past when a crash had happened - was that just me ? or was that
removed ?

	Also - interestingly; the migration code writes things to the splash
screen as it works - which we should probably vector out to the
unxsplash quick-starter for that case.



 michael.meeks at novell.com  <><, Pseudo Engineer, itinerant idiot

More information about the LibreOffice mailing list