/usr/kde/3/bin/startkde contains the following lines, effectively removing the user's existing KDE configuration: rm -rf ~/.kde ln -fs ~/.kde3 ~/.kde [ -e "~/.kde3" ] || mkdir ~/.kde3
Well, I need that symlink so that kde2 and kde3 (and optionally other versions if the user wants to have several installed) can have separate config dirs. I could replace rm -rf ~/.kde with: [ -d "~/.kde" ] && mv -f ~/.kde ~/.kde.old Where -d checks for a dir (i.e. not a symlink), I think. But, even if I do it I've no easy way to tell the user from startkde that his old configuration is in .kde.old now. Of cours, for really clean updates (first runs) I could say: [ -f ~/.kde ] && [ ! -d ~/.kde3 ] && mv ~/.kde ~/.kde3 What do you think?
The easiest thing would be to have KDEHOME=~/.kde2 for KDE2 and KDEHOME=~/.kde3 for version 3. If that is not possible, then perhaps something like you suggested. Note that for at least my /bin/sh using [ -d "~/.kde" ] doesn't work, it's always false. I have to leave out the quotes: [ -d ~/.kde ] (don't know what happens if ~ contains whitespace, maybe [ -d "$HOME/.kde" ] would be the best solution)
That's right. I forgot about $KDEHOME. I remember testing it once and deciding in favour of an actual ~/.kde->.kde3 symlink because something didn't work out. But that was back in the pre-3.0 days and I'll test it again now to be sure we can't use it because it'd be the best solution probably.
I tried steting $KDEHOME and nothing happens (!). KDE still uses ~/.kde. For now, if a ~/.kde directory exists I'll move it to to ~/.kde.backup. I've changed this in the startkde for 3.0.2 which should be available in a few days.
3.0.2 out, closing.