summaryrefslogtreecommitdiffstats
path: root/debian/lenny/tdebase/debian/ksmserver-trinity.preinst
blob: 36d174e27a0c4122f4fed5c7f6352ef6aa4d7243 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#! /bin/sh -e

package_name=ksmserver-trinity

case "$1" in

    upgrade)
	# Remove old-style Plasma diversions
	divert=`dpkg-divert --listpackage "/usr/bin/plasma"`
	if [ -n "$divert" ]; then
	    if [ "$divert" = "LOCAL" ]; then
	        dpkg-divert --local --rename --remove /usr/bin/plasma
	    else
	        dpkg-divert --package $package_name --rename --remove /usr/bin/plasma
	    fi
	fi
	divert=`dpkg-divert --listpackage "/usr/bin/plasma-desktop"`
	if [ -n "$divert" ]; then
	    if [ "$divert" = "LOCAL" ]; then
	        dpkg-divert --local --rename --remove /usr/bin/plasma-desktop
	    else
	        dpkg-divert --package $package_name --rename --remove /usr/bin/plasma-desktop
	    fi
	fi
	mkdir -p /usr/share/autostart
    ;;

    install)
    ;;

    abort-upgrade)
    ;;

    *)
        echo "preinst called with unknown argument \`$1'" >&2
        exit 1
    ;;

esac

#DEBHELPER#

exit 0