summaryrefslogtreecommitdiff
path: root/japanese/font-mona-ttf/files/pkg-install.in
diff options
context:
space:
mode:
Diffstat (limited to 'japanese/font-mona-ttf/files/pkg-install.in')
-rw-r--r--japanese/font-mona-ttf/files/pkg-install.in22
1 files changed, 22 insertions, 0 deletions
diff --git a/japanese/font-mona-ttf/files/pkg-install.in b/japanese/font-mona-ttf/files/pkg-install.in
new file mode 100644
index 000000000000..ae01688e7b99
--- /dev/null
+++ b/japanese/font-mona-ttf/files/pkg-install.in
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+case $2 in
+POST-INSTALL)
+ cd %%FONTSDIR%%
+ touch fonts.dir
+ sed -e '/mona\.ttf/d' fonts.dir > fonts.dir.tmp
+ numfonts=$(echo $(cat fonts.dir.tmp %%DIRFILE%% | wc -l) - 2 | bc)
+ echo ${numfonts} > fonts.dir
+ sed -e 1d fonts.dir.tmp >> fonts.dir
+ sed -e 1d %%DIRFILE%% >> fonts.dir
+ rm -f fonts.dir.tmp fonts.alias.tmp
+;;
+DEINSTALL)
+ cd %%FONTSDIR%%
+ touch fonts.dir
+ sed -e '/mona\.ttf/d' fonts.dir > fonts.dir.tmp
+ numfonts=$(echo $(cat fonts.dir.tmp | wc -l) - 2 | bc)
+ echo ${numfonts} > fonts.dir
+ sed -e 1d fonts.dir.tmp >> fonts.dir
+;;
+esac