OLD | NEW |
1 #!/bin/sh | 1 #!/bin/sh |
2 #--------------------------------------------- | 2 #--------------------------------------------- |
3 # xdg-desktop-icon | 3 # xdg-desktop-icon |
4 # | 4 # |
5 # Utility script to install desktop items on a Linux desktop. | 5 # Utility script to install desktop items on a Linux desktop. |
6 # | 6 # |
7 # Refer to the usage() function below for usage. | 7 # Refer to the usage() function below for usage. |
8 # | 8 # |
9 # Copyright 2009-2010, Fathi Boudra <fabo@freedesktop.org> | 9 # Copyright 2009-2010, Fathi Boudra <fabo@freedesktop.org> |
10 # Copyright 2009-2010, Rex Dieter <rdieter@fedoraproject.org> | 10 # Copyright 2009-2010, Rex Dieter <rdieter@fedoraproject.org> |
(...skipping 416 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
427 case "$(uname 2>/dev/null)" in | 427 case "$(uname 2>/dev/null)" in |
428 Darwin) | 428 Darwin) |
429 DE=darwin; | 429 DE=darwin; |
430 ;; | 430 ;; |
431 esac | 431 esac |
432 fi | 432 fi |
433 | 433 |
434 if [ x"$DE" = x"gnome" ]; then | 434 if [ x"$DE" = x"gnome" ]; then |
435 # gnome-default-applications-properties is only available in GNOME 2.x | 435 # gnome-default-applications-properties is only available in GNOME 2.x |
436 # but not in GNOME 3.x | 436 # but not in GNOME 3.x |
437 which gnome-default-applications-properties 2> /dev/null || DE="gnome3" | 437 which gnome-default-applications-properties > /dev/null 2> /dev/null || DE
="gnome3" |
438 fi | 438 fi |
439 } | 439 } |
440 | 440 |
441 #---------------------------------------------------------------------------- | 441 #---------------------------------------------------------------------------- |
442 # kfmclient exec/openURL can give bogus exit value in KDE <= 3.5.4 | 442 # kfmclient exec/openURL can give bogus exit value in KDE <= 3.5.4 |
443 # It also always returns 1 in KDE 3.4 and earlier | 443 # It also always returns 1 in KDE 3.4 and earlier |
444 # Simply return 0 in such case | 444 # Simply return 0 in such case |
445 | 445 |
446 kfmclient_fix_exit_code() | 446 kfmclient_fix_exit_code() |
447 { | 447 { |
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
578 rm -f "$x/$basefile" | 578 rm -f "$x/$basefile" |
579 fi | 579 fi |
580 done | 580 done |
581 | 581 |
582 ;; | 582 ;; |
583 esac | 583 esac |
584 | 584 |
585 exit_success | 585 exit_success |
586 | 586 |
587 | 587 |
OLD | NEW |