Debian Codegraph @

debian/fonts-ipaexfont-gothic.postinst

raw
1 #!/bin/sh
2 #
3 # see: dh_installdeb(1)
4
5 set -e
6
7 # font alternatives
8 ALT_GOTHIC_NAME="fonts-japanese-gothic"
9 GOTHIC_FONT_ENTRY="/usr/share/fonts/opentype/ipaexfont-gothic/ipaexg.ttf"
10 FONT_PRIORITY=120
11
12 add_alternate_gothic_font_entry()
13 {
14 update-alternatives --install \
15 /usr/share/fonts/truetype/$ALT_GOTHIC_NAME.ttf \
16 $ALT_GOTHIC_NAME.ttf \
17 $GOTHIC_FONT_ENTRY \
18 $FONT_PRIORITY
19 }
20
21
22 # summary of how this script can be called:
23 # * <postinst> `configure' <most-recently-configured-version>
24 # * <old-postinst> `abort-upgrade' <new version>
25 # * <conflictor's-postinst> `abort-remove' `in-favour' <package>
26 # <new-version>
27 # * <postinst> `abort-remove'
28 # * <deconfigured's-postinst> `abort-deconfigure' `in-favour'
29 # <failed-install-package> <version> `removing'
30 # <conflicting-package> <version>
31 # for details, see http://www.debian.org/doc/debian-policy/ or
32 # the debian-policy package
33
34
35 case "$1" in
36 configure)
37 add_alternate_gothic_font_entry
38 ;;
39
40 abort-upgrade|abort-remove|abort-deconfigure)
41 ;;
42
43 *)
44 echo "postinst called with unknown argument \`$1'" >&2
45 exit 1
46 ;;
47 esac
48
49 # dh_installdeb will replace this with shell code automatically
50 # generated by other debhelper scripts.
51
52 #DEBHELPER#
53
54 exit 0