| OLD | NEW |
| 1 #!/bin/sh | 1 #!/bin/sh |
| 2 #--------------------------------------------- | 2 #--------------------------------------------- |
| 3 # xdg-desktop-menu | 3 # xdg-desktop-menu |
| 4 # | 4 # |
| 5 # Utility script to install menu items on a Linux desktop. | 5 # Utility script to install menu items on a Linux desktop. |
| 6 # Refer to the usage() function below for usage. | 6 # Refer to the usage() function below for usage. |
| 7 # | 7 # |
| 8 # Copyright 2009-2010, Fathi Boudra <fabo@freedesktop.org> | 8 # Copyright 2009-2010, Fathi Boudra <fabo@freedesktop.org> |
| 9 # Copyright 2009-2010, Rex Dieter <rdieter@fedoraproject.org> | 9 # Copyright 2009-2010, Rex Dieter <rdieter@fedoraproject.org> |
| 10 # Copyright 2006, Kevin Krammer <kevin.krammer@gmx.at> | 10 # Copyright 2006, Kevin Krammer <kevin.krammer@gmx.at> |
| (...skipping 677 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 688 case "$(uname 2>/dev/null)" in | 688 case "$(uname 2>/dev/null)" in |
| 689 Darwin) | 689 Darwin) |
| 690 DE=darwin; | 690 DE=darwin; |
| 691 ;; | 691 ;; |
| 692 esac | 692 esac |
| 693 fi | 693 fi |
| 694 | 694 |
| 695 if [ x"$DE" = x"gnome" ]; then | 695 if [ x"$DE" = x"gnome" ]; then |
| 696 # gnome-default-applications-properties is only available in GNOME 2.x | 696 # gnome-default-applications-properties is only available in GNOME 2.x |
| 697 # but not in GNOME 3.x | 697 # but not in GNOME 3.x |
| 698 which gnome-default-applications-properties > /dev/null 2> /dev/null || DE
="gnome3" | 698 which gnome-default-applications-properties > /dev/null 2>&1 || DE="gnome
3" |
| 699 fi | 699 fi |
| 700 } | 700 } |
| 701 | 701 |
| 702 #---------------------------------------------------------------------------- | 702 #---------------------------------------------------------------------------- |
| 703 # kfmclient exec/openURL can give bogus exit value in KDE <= 3.5.4 | 703 # kfmclient exec/openURL can give bogus exit value in KDE <= 3.5.4 |
| 704 # It also always returns 1 in KDE 3.4 and earlier | 704 # It also always returns 1 in KDE 3.4 and earlier |
| 705 # Simply return 0 in such case | 705 # Simply return 0 in such case |
| 706 | 706 |
| 707 kfmclient_fix_exit_code() | 707 kfmclient_fix_exit_code() |
| 708 { | 708 { |
| (...skipping 598 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1307 | 1307 |
| 1308 ;; | 1308 ;; |
| 1309 esac | 1309 esac |
| 1310 done | 1310 done |
| 1311 | 1311 |
| 1312 if [ x"$update" = x"yes" ] ; then | 1312 if [ x"$update" = x"yes" ] ; then |
| 1313 update_desktop_database | 1313 update_desktop_database |
| 1314 fi | 1314 fi |
| 1315 | 1315 |
| 1316 exit_success | 1316 exit_success |
| OLD | NEW |