Hello community, here is the log from the commit of package update-desktop-files checked in at Mon Oct 6 16:13:52 CEST 2008. -------- --- update-desktop-files/update-desktop-files.changes 2008-09-26 00:50:48.000000000 +0200 +++ /mounts/work_src_done/STABLE/update-desktop-files/update-desktop-files.changes 2008-10-06 16:03:14.303873000 +0200 @@ -1,0 +2,21 @@ +Thu Oct 2 18:16:16 CEST 2008 - vuntz@suse.de + +- Add a -t/--trim option to suse_update_desktop_file.sh in order + to trim all translations from a desktop file. The goal is to + have the desktops use gettext to translate data from those files + and to make it easy to update translations by just shipping an + updated mo file. This is for fate#301344. +- This change requires a change in /usr/lib/rpm/suse_macros (rpm + package). + +------------------------------------------------------------------- +Thu Oct 2 17:02:32 CEST 2008 - ke@suse.de + +- update translations. + +------------------------------------------------------------------- +Tue Sep 30 10:02:59 CEST 2008 - dmueller@suse.de + +- fix mimetype.prov to not break for most KDE packages + +------------------------------------------------------------------- calling whatdependson for head-i586 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ update-desktop-files.spec ++++++ --- /var/tmp/diff_new_pack.HO5172/_old 2008-10-06 16:10:53.000000000 +0200 +++ /var/tmp/diff_new_pack.HO5172/_new 2008-10-06 16:10:53.000000000 +0200 @@ -20,7 +20,7 @@ Name: update-desktop-files Version: 11.0 -Release: 54 +Release: 55 Summary: A Build Tool to Update Desktop Files License: GPL v2 or later Group: Development/Tools/Building @@ -110,6 +110,18 @@ %defattr(-,root,root) %changelog +* Thu Oct 02 2008 vuntz@suse.de +- Add a -t/--trim option to suse_update_desktop_file.sh in order + to trim all translations from a desktop file. The goal is to + have the desktops use gettext to translate data from those files + and to make it easy to update translations by just shipping an + updated mo file. This is for fate#301344. +- This change requires a change in /usr/lib/rpm/suse_macros (rpm + package). +* Thu Oct 02 2008 ke@suse.de +- update translations. +* Tue Sep 30 2008 dmueller@suse.de +- fix mimetype.prov to not break for most KDE packages * Thu Sep 25 2008 sreeves@suse.de - add mimetype.prov to generate mime type rpm provides at build time * Fri Sep 19 2008 ke@suse.de ++++++ desktop-translations.tar.bz2 ++++++ update-desktop-files/desktop-translations.tar.bz2 /mounts/work_src_done/STABLE/update-desktop-files/desktop-translations.tar.bz2 differ: byte 11, line 1 ++++++ mimetypes.prov ++++++ --- update-desktop-files/mimetypes.prov 2008-09-12 07:33:01.000000000 +0200 +++ /mounts/work_src_done/STABLE/update-desktop-files/mimetypes.prov 2008-09-30 10:24:58.000000000 +0200 @@ -1,17 +1,17 @@ #!/bin/sh +# vim: sw=4 et # Transform desktop mimetype info into RPM provides OLD_IFS="$IFS" while read instfile ; do - case "$instfile" in - *.desktop) - mime=`cat $instfile | grep MimeType | cut -d'=' -f2` - IFS=';' - for type in $mime ; do - echo 'mimetype('$type')' - done - ;; - esac - done - IFS=$OLD_IFS - + case "$instfile" in + *.desktop) + mime=$(sed -re '/^MimeType *= *([a-zA-Z0-9. _/;-]*)/!d' $instfile | cut -d'=' -f2) + IFS=';' + for type in $mime ; do + echo 'mimetype('$type')' + done + ;; + esac +done +IFS=$OLD_IFS ++++++ suse_update_desktop_file.sh ++++++ --- update-desktop-files/suse_update_desktop_file.sh 2008-03-28 05:05:37.000000000 +0100 +++ /mounts/work_src_done/STABLE/update-desktop-files/suse_update_desktop_file.sh 2008-10-06 16:02:43.875187000 +0200 @@ -13,6 +13,7 @@ # INSTALL=no I18N=yes +TRIM=no CREATE=no RESET=no UNIMPORTANT=no @@ -29,6 +30,10 @@ I18N=no shift continue;; + -t|--trim-i18n) + TRIM=yes + shift + continue;; -i|--install) INSTALL=yes shift @@ -326,19 +331,28 @@ echo "ERROR: $FILE is not an UTF-8 file" exit 1 fi - # - # Merge translations - # - cp $FILE ${FILE}.old - /usr/bin/suse-desktop-merge $FILE > ${FILE}_ || exit 1 - perl /usr/share/update-desktop-files/untranslate.pl ${FILE}_ > ${FILE}.new - if ! cmp -s ${FILE}.old ${FILE}.new; then - echo "UNTRANSLATE DOES NOT WORK" - diff -u ${FILE}.old ${FILE}.new - exit 1 + + if [ "$TRIM" = "no" ]; then + # + # Merge translations + # + cp $FILE ${FILE}.old + /usr/bin/suse-desktop-merge $FILE > ${FILE}_ || exit 1 + perl /usr/share/update-desktop-files/untranslate.pl ${FILE}_ > ${FILE}.new + if ! cmp -s ${FILE}.old ${FILE}.new; then + echo "UNTRANSLATE DOES NOT WORK" + diff -u ${FILE}.old ${FILE}.new + exit 1 + fi + mv ${FILE}_ $FILE + rm -f ${FILE}.old ${FILE}.new + else + # + # Trim translations (desktops will use gettext to find them) + # + grep -v -E '^Name[|^GenericName[|^Comment[' $FILE > ${FILE}_ + mv ${FILE}_ $FILE fi - mv ${FILE}_ $FILE - rm -f ${FILE}.old ${FILE}.new else # # this file will not get translated ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... -- To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit+help@opensuse.org