summaryrefslogtreecommitdiffstats
path: root/r14-xdg-update
diff options
context:
space:
mode:
Diffstat (limited to 'r14-xdg-update')
-rw-r--r--r14-xdg-update18
1 files changed, 17 insertions, 1 deletions
diff --git a/r14-xdg-update b/r14-xdg-update
index faedfdad8..f383f717c 100644
--- a/r14-xdg-update
+++ b/r14-xdg-update
@@ -114,6 +114,8 @@ if [ "$R14_UPDATED" != "true" ] || [ "$FORCE" = "true" ]; then
echo -e "Updating *.desktop files."
find "$PROFILE_DIR" -name "*.desktop" -exec sed -i 's|X-KDE-|X-TDE-|g' {} \; 2>/dev/null
find "$PROFILE_DIR" -name "*.desktop" -exec sed -i 's|KDE\;|TDE\;|g' {} \; 2>/dev/null
+ find "$HOME/.local" -name "*.desktop" -exec sed -i 's|X-KDE-|X-TDE-|g' {} \; 2>/dev/null
+ find "$HOME/.local" -name "*.desktop" -exec sed -i 's|KDE\;|TDE\;|g' {} \; 2>/dev/null
Message_Prefix
echo -e "Updating references of $TDEDIR/share/applications/kde to share/applications/tde."
# Exclude KMail mail files --- we don't want to touch those files.
@@ -125,6 +127,8 @@ if [ "$R14_UPDATED" != "true" ] || [ "$FORCE" = "true" ]; then
sed -i 's|CommandURL=kde-|CommandURL=tde-|g' "$PROFILE_DIR/share/config/khotkeysrc" 2>/dev/null
sed -i 's|K Menu - kde-|TDE Menu - tde-|g' "$PROFILE_DIR/share/config/khotkeysrc" 2>/dev/null
sed -i 's|Name=K Menu|Name=TDE Menu|g' "$PROFILE_DIR/share/config/khotkeysrc" 2>/dev/null
+ sed -i 's|in KDE stands|in TDE stands|g' "$PROFILE_DIR/share/config/khotkeysrc" 2>/dev/null
+ sed -i 's| use KDE| use TDE|g' "$PROFILE_DIR/share/config/khotkeysrc" 2>/dev/null
Message_Prefix
echo -e "Updating some text strings in khotkeysrc."
sed -i 's|Go to KDE Website|Go to TDE Website|g' "$PROFILE_DIR/share/config/khotkeysrc" 2>/dev/null
@@ -179,6 +183,11 @@ if [ "$R14_UPDATED" != "true" ] || [ "$FORCE" = "true" ]; then
done
)
+ # Update the user's customized menu.
+ if [ -r $HOME/.config/menus/applications-kmenuedit.menu ]; then
+ sed -i 's|<Filename>kde-|<Filename>tde-|g' $HOME/.config/menus/applications-kmenuedit.menu
+ fi
+
# Perform some nominal update validations.
# This test includes *.desktop files in the profile Autostart directory.
R14_UPDATE_TEST1="`find \"$PROFILE_DIR\" -name \"*.desktop\" -exec grep \"X-KDE\" {} \; 2>/dev/null`"
@@ -223,9 +232,16 @@ if [ "$R14_UPDATED" != "true" ] || [ "$FORCE" = "true" ]; then
Display_Message "$MESSAGE"
fi
fi
+ if [ -r $HOME/.config/menus/applications-kmenuedit.menu ]; then
+ R14_UPDATE_TEST9="`grep -q \"<Filename>kde-\" \"$HOME/.config/menus/applications-kmenuedit.menu\" 2>/dev/null`"
+ if [ "$R14_UPDATE_TEST9" != "" ]; then
+ MESSAGE="Some Trinity profile R14 XDG compliance updates failed.\n\n(Check applications-kmenuedit.menu for '<Filename>kde-'.)"
+ Display_Message "$MESSAGE"
+ fi
+ fi
if [ "$R14_UPDATE_TEST1" = "" ] && [ "$R14_UPDATE_TEST2" = "" ] && [ "$R14_UPDATE_TEST3" = "" ] \
&& [ "$R14_UPDATE_TEST4" = "" ] && [ "$R14_UPDATE_TEST5" = "" ] && [ "$R14_UPDATE_TEST6" = "" ] \
- && [ "$R14_UPDATE_TEST7" = "" ] && [ "$R14_UPDATE_TEST8" = "" ]; then
+ && [ "$R14_UPDATE_TEST7" = "" ] && [ "$R14_UPDATE_TEST8" = "" ] && [ "$R14_UPDATE_TEST9" = "" ]; then
$TDEDIR/bin/kwriteconfig --file kdeglobals --group "R14 XDG Updates" --key Updated --type bool 'true'
else
$TDEDIR/bin/kwriteconfig --file kdeglobals --group "R14 XDG Updates" --key Updated --type bool 'false'