|
|
@ -1,30 +1,50 @@
|
|
|
|
#!/bin/sh
|
|
|
|
#!/bin/sh -e
|
|
|
|
|
|
|
|
# This script can be called in the following ways:
|
|
|
|
#
|
|
|
|
#
|
|
|
|
# see: dh_installdeb(1)
|
|
|
|
# After the package was removed:
|
|
|
|
|
|
|
|
# <postrm> remove
|
|
|
|
|
|
|
|
#
|
|
|
|
|
|
|
|
# After the package was purged:
|
|
|
|
|
|
|
|
# <postrm> purge
|
|
|
|
|
|
|
|
#
|
|
|
|
|
|
|
|
# After the package was upgraded:
|
|
|
|
|
|
|
|
# <old-postrm> upgrade <new-version>
|
|
|
|
|
|
|
|
# if that fails:
|
|
|
|
|
|
|
|
# <new-postrm> failed-upgrade <old-version>
|
|
|
|
|
|
|
|
#
|
|
|
|
|
|
|
|
#
|
|
|
|
|
|
|
|
# After all of the packages files have been replaced:
|
|
|
|
|
|
|
|
# <postrm> disappear <overwriting-package> <version>
|
|
|
|
|
|
|
|
#
|
|
|
|
|
|
|
|
#
|
|
|
|
|
|
|
|
# If preinst fails during install:
|
|
|
|
|
|
|
|
# <new-postrm> abort-install
|
|
|
|
|
|
|
|
#
|
|
|
|
|
|
|
|
# If preinst fails during upgrade of removed package:
|
|
|
|
|
|
|
|
# <new-postrm> abort-install <old-version>
|
|
|
|
|
|
|
|
#
|
|
|
|
|
|
|
|
# If preinst fails during upgrade:
|
|
|
|
|
|
|
|
# <new-postrm> abort-upgrade <old-version>
|
|
|
|
|
|
|
|
|
|
|
|
set -e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# summary of how this script can be called:
|
|
|
|
case "$1" in
|
|
|
|
# * <postrm> `remove'
|
|
|
|
remove)
|
|
|
|
# * <postrm> `purge'
|
|
|
|
update-alternatives \
|
|
|
|
# * <old-postrm> `upgrade' <new-version>
|
|
|
|
--remove default.plymouth /lib/plymouth/themes/lubuntu-logo/lubuntu-logo.plymouth
|
|
|
|
# * <new-postrm> `failed-upgrade' <old-version>
|
|
|
|
|
|
|
|
# * <new-postrm> `abort-install'
|
|
|
|
if which update-initramfs >/dev/null 2>&1
|
|
|
|
# * <new-postrm> `abort-install' <old-version>
|
|
|
|
then
|
|
|
|
# * <new-postrm> `abort-upgrade' <old-version>
|
|
|
|
update-initramfs -u
|
|
|
|
# * <disappearer's-postrm> `disappear' <overwriter>
|
|
|
|
fi
|
|
|
|
# <overwriter-version>
|
|
|
|
;;
|
|
|
|
# for details, see http://www.debian.org/doc/debian-policy/ or
|
|
|
|
|
|
|
|
# the debian-policy package
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
purge)
|
|
|
|
|
|
|
|
;;
|
|
|
|
|
|
|
|
|
|
|
|
case "$1" in
|
|
|
|
upgrade|failed-upgrade|disappear)
|
|
|
|
purge|remove)
|
|
|
|
|
|
|
|
# FIXME: do this with alternatives
|
|
|
|
|
|
|
|
/usr/sbin/plymouth-set-default-theme --rebuild-initrd ubuntu-logo
|
|
|
|
|
|
|
|
;;
|
|
|
|
;;
|
|
|
|
|
|
|
|
|
|
|
|
upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
|
|
|
|
abort-install|abort-upgrade)
|
|
|
|
;;
|
|
|
|
;;
|
|
|
|
|
|
|
|
|
|
|
|
*)
|
|
|
|
*)
|
|
|
@ -34,5 +54,4 @@ case "$1" in
|
|
|
|
esac
|
|
|
|
esac
|
|
|
|
|
|
|
|
|
|
|
|
#DEBHELPER#
|
|
|
|
#DEBHELPER#
|
|
|
|
|
|
|
|
|
|
|
|
exit 0
|
|
|
|
exit 0
|
|
|
|