diff options
author | Frederic Crozat <fcrozat@mandriva.com> | 2007-05-11 15:57:08 +0000 |
---|---|---|
committer | Frederic Crozat <fcrozat@mandriva.com> | 2007-05-11 15:57:08 +0000 |
commit | 5e1dd28ef5fa3033f4bc394e314eb89142546bfb (patch) | |
tree | 449af97a57153a4dff45c7e9a8b5e2077a67f8f5 /xinit.d/desktop-directories | |
parent | 90ae1dda6727feaefcf03e250b01a1d02fc514d5 (diff) | |
download | common-data-5e1dd28ef5fa3033f4bc394e314eb89142546bfb.tar common-data-5e1dd28ef5fa3033f4bc394e314eb89142546bfb.tar.gz common-data-5e1dd28ef5fa3033f4bc394e314eb89142546bfb.tar.bz2 common-data-5e1dd28ef5fa3033f4bc394e314eb89142546bfb.tar.xz common-data-5e1dd28ef5fa3033f4bc394e314eb89142546bfb.zip |
Fix handling for zh locales (Mdv bug #30215)
Diffstat (limited to 'xinit.d/desktop-directories')
-rwxr-xr-x | xinit.d/desktop-directories | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/xinit.d/desktop-directories b/xinit.d/desktop-directories index ffe7512..5f01564 100755 --- a/xinit.d/desktop-directories +++ b/xinit.d/desktop-directories @@ -19,8 +19,12 @@ if [ "$UID" != "0" -a ! -e $MDK_FOLDERS ]; then for file in /usr/share/mdk/menu/*-mdk.desktop.template ; do TARGET_DIR=`grep -m1 -F Name[$locale]= $file | sed -e 's|.*=||g'` if [ -z "$TARGET_DIR" ]; then - locale=`echo $locale | sed -e 's/_.*//g' -e 's/@.*//g'` + locale=`echo $locale | sed -e 's/@.*//g' -e 's/\..*//g'` TARGET_DIR=`grep -m1 -F Name[$locale]= $file | sed -e 's|.*=||g'` + if [ -z "$TARGET_DIR" ]; then + locale=`echo $locale | sed -e 's/_.*//g'` + TARGET_DIR=`grep -m1 -F Name[$locale]= $file | sed -e 's|.*=||g'` + fi fi if [ -z "$TARGET_DIR" ]; then |