WARNING_MESSAGE="Trinity R14 XDG compliance updates will not be performed.\n\nWithout R14 XDG compliance updates, some Trinity apps will fail to\nfunction properly.\n\nFailures include the following:\n\n* Many left-side icon lists will not populate,\n such as the Panel and Konqueror configuration dialogs.\n\n* User-defined keyboard shortcuts fail (khotkeysrc).\n System defined shortcuts remain functional.\n\n* User-defined app preferences fail (profilerc).\n\n* Konqueror navigation/sidebar panel won't open.\n\n* User-defined konqueror service menus, kicker customization,\n konqueror sidebar, Recent Documents list fail.\n\nPossible remedies:\n\n* If necessary contact your system administrator."
WARNING_MESSAGE="Trinity R14 XDG compliance updates will not be performed automatically.\n\nWithout R14 XDG compliance updates, some Trinity apps will fail to\nfunction properly.\n\nFailures include the following:\n\n* Many left-side icon lists will not populate,\n such as the Panel and Konqueror configuration dialogs.\n\n* User-defined keyboard shortcuts fail (khotkeysrc).\n System defined shortcuts remain functional.\n\n* User-defined app preferences fail (profilerc).\n\n* Konqueror navigation/sidebar panel won't open.\n\n* User-defined konqueror service menus, kicker customization,\n konqueror sidebar, Recent Documents list fail.\n\nPlease take appropriate action.\n"
# As the user should not be logged into a Trinity session when running
# this script, or an administrator might run this script remotely, the
# $TDEHOME variable probably is not set or knowable from within this script.
# We presume $HOME/.trinity, but provide a way to pass an environment
# $TDEHOME variable might not be set or knowable from within this script.
# We presume $HOME/.trinity and provide a way to pass an environment
# variable to change that location.
if [ "$TDEHOME" = "" ]; then
PROFILE_DIR=${PROFILE_DIR:-"$HOME/.trinity"}
@ -82,19 +82,19 @@ else
PROFILE_DIR="$TDEHOME"
fi
if [ ! -d "$PROFILE_DIR" ]; then
MESSAGE="Unable to determine the user profile directory.\n\n${WARNING_MESSAGE}"
MESSAGE="Warning! Unable to find the user profile directory $PROFILE_DIR.\n\n${WARNING_MESSAGE}"
# Are we in X? Display an X dialog explaining breakage.
# Are we in X? Display an X dialog explaining breakage.
if [ "$DISPLAY" != "" ]; then
echo "[r14-xdg-update] Warning! The profile directory $PROFILE_DIR is a" 1>&2
echo " sym link to $TDEHOME_LINK!" 1>&2
echo " R14 updates will not be performed because Trinity needs its own separate profile directory." 1>&2
echo " Without R14 updates some Trinity apps will fail to function correctly." 1>&2
echo " sym link to $TDEHOME_LINK!" 1>&2
echo " R14 updates will not be performed because Trinity needs its own" 1>&2
echo " separate profile directory." 1>&2
echo " Without R14 updates some Trinity apps will fail to function correctly." 1>&2
fi
MESSAGE="Oops! The profile directory $PROFILE_DIR is a sym link to $TDEHOME_LINK.\n\n${WARNING_MESSAGE}\n\n* Break the sym link to allow Trinity to create a fresh Trinity profile.\n\n* Use the migratekde3 script to migrate a KDE3 profile to Trinity."
MESSAGE="Oops! The profile directory $PROFILE_DIR is a sym link to $TDEHOME_LINK.\n\n${WARNING_MESSAGE}\nPossible remedies:\n\n* Contact your system administrator.\n\n* Break the sym link to force creating a fresh Trinity profile.\n\n* Use the migratekde3 script to migrate a KDE3 profile to Trinity."
# Are we in X? Display an X dialog explaining breakage.
if [ "$DISPLAY" != "" ]; then
MESSAGE="${MESSAGE}\n\nSelecting the Continue button means retaining the KDE3 profile and\nbreaking the sym link. With the sym link broken, run the migratekde3\nscript before restarting Trinity to migrate a KDE3 profile or\nallow Trinity to create a fresh profile."
# User selected the Quit button: quit this script and exit X.
unset PROFILE_DIR
unset TDEHOME_LINK
Message_Prefix
echo "The user chose to quit."
exit 1
else
# User selected the Continue button: continue this script and start TDE.
Message_Prefix
echo "The user chose to continue, which will break the sym link."
BREAK_SYMLINK="true"
fi
else
echo
echo -e "$MESSAGE"
echo
Wait_For_Response "Break the sym link now and migrate the $TDEHOME_LINK profile to a new Trinity profile?"
Wait_For_Response "Break the sym link now?"
Proceed_From_Response
BREAK_SYMLINK="true"
fi
if [ "$BREAK_SYMLINK" = "true" ]; then
unlink "$HOME/.trinity" 2>/dev/null
if [ "`readlink \"$HOME/.trinity\"`" != "" ]; then
echo "Unable to break the sym link. Check your file and directory privileges. Quitting."
unset PROFILE_DIR
unset TDEHOME_LINK
exit 1
if [ "`readlink \"$HOME/.trinity\"`" = "" ]; then
MESSAGE="Sym link broken. With the sym link broken, run the migratekde3\nscript before restarting Trinity to migrate a KDE3 profile or\nallow Trinity to create a fresh profile."
if [ "$DISPLAY" != "" ]; then
Message_Prefix
fi
echo -e "$MESSAGE"
echo
else
sh $TDEDIR/bin/migratekde3
MESSAGE="Unable to break the sym link. Check file and directory privileges. Quitting."
if [ "$DISPLAY" != "" ]; then
Message_Prefix
fi
echo "$MESSAGE"
echo
fi
fi
unset PROFILE_DIR
unset TDEHOME_LINK
exit 1
fi
unset TDEHOME_LINK
@ -199,13 +221,7 @@ if [ "$TDE_FULL_SESSION" != "" ] || [ "$TDE_SESSION_UID" != "" ]; then
MESSAGE="You are running this script from within a Trinity session.\n\nMost files can be updated \"live\" but some cannot, such as kdeglobals.\n\nThis script might complete successfully and might not."
# Are we in X? Display an X dialog explaining breakage.