uim-chewing.postinst 1.34 KB
Newer Older
1 2 3 4
#! /bin/sh
# postinst script for uim
#
# see: dh_installdeb(1)
Kan-Ru Chen's avatar
Kan-Ru Chen committed
5 6 7

set -e

8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
# summary of how this script can be called:
#        * <postinst> `configure' <most-recently-configured-version>
#        * <old-postinst> `abort-upgrade' <new version>
#        * <conflictor's-postinst> `abort-remove' `in-favour' <package>
#          <new-version>
#        * <deconfigured's-postinst> `abort-deconfigure' `in-favour'
#          <failed-install-package> <version> `removing'
#          <conflicting-package> <version>
# for details, see http://www.debian.org/doc/debian-policy/ or
# the debian-policy package
#
# quoting from the policy:
#     Any necessary prompting should almost always be confined to the
#     post-installation script, and should be protected with a conditional
#     so that unnecessary prompting doesn't happen if a package's
#     installation fails and the `postinst' is called with `abort-upgrade',
#     `abort-remove' or `abort-deconfigure'.
Kan-Ru Chen's avatar
Kan-Ru Chen committed
25 26 27

case "$1" in
    configure)
28 29 30
	if which uim-module-manager >/dev/null 2>&1; then
		uim-module-manager --register chewing --path /etc/uim
	fi
Kan-Ru Chen's avatar
Kan-Ru Chen committed
31 32 33 34 35 36 37
    ;;

    abort-upgrade|abort-remove|abort-deconfigure)

    ;;

    *)
38 39
	echo "postinst called with unknown argument \`$1'" >&2
	exit 1
Kan-Ru Chen's avatar
Kan-Ru Chen committed
40 41 42
    ;;
esac

43 44
# dh_installdeb will replace this with shell code automatically
# generated by other debhelper scripts.
Kan-Ru Chen's avatar
Kan-Ru Chen committed
45

46
#DEBHELPER#
Kan-Ru Chen's avatar
Kan-Ru Chen committed
47 48

exit 0