Fix up action list in Appendix A.
[ibg.git] / tools / uninstall-emerald.sh
1 #!/bin/sh
2
3 # This script uninstalls the Emerald CTAN package from $TEXMFLOCAL.
4 # It may be executed anywhere.
5
6 # Created by David Griffith <dave@661.org>
7 # Released into the public domain 2016
8
9 if [ `ps -o uid= $$` -ne 0 ] ; then
10         echo "This script must be run as root"
11         exit 1
12 fi
13
14 TEXMFLOCAL=`kpsewhich -var TEXMFLOCAL`
15
16 echo "Deleting emerald from $TEXMFLOCAL..."
17
18 rm -f $TEXMFLOCAL/fonts/map/dvips/emerald.map
19 rm -rf $TEXMFLOCAL/fonts/afm/emerald
20 rm -rf $TEXMFLOCAL/fonts/tfm/emerald
21 rm -rf $TEXMFLOCAL/fonts/type1/emerald
22 rm -rf $TEXMFLOCAL/fonts/vf/emerald
23 rm -rf $TEXMFLOCAL/tex/latex/emerald
24
25 rm -f $TEXMFLOCAL/other/apicture.ttf \
26         $TEXMFLOCAL/other/AUGIE___.INF \
27         $TEXMFLOCAL/other/DECAC___.INF \
28         $TEXMFLOCAL/other/DECADENC.INF \
29         $TEXMFLOCAL/other/DECAIAL_.INF \
30         $TEXMFLOCAL/other/DECAI___.INF \
31         $TEXMFLOCAL/other/DECAIM__.INF \
32         $TEXMFLOCAL/other/DECAITD_.INF \
33         $TEXMFLOCAL/other/DECAWTD_.INF \
34         $TEXMFLOCAL/other/INTID___.INF \
35         $TEXMFLOCAL/other/INTIMACY.INF \
36         $TEXMFLOCAL/other/J.D.____.INF \
37         $TEXMFLOCAL/other/movieola.inf \
38         $TEXMFLOCAL/other/moviettt.inf \
39         $TEXMFLOCAL/other/POOKIE__.INF \
40         $TEXMFLOCAL/other/SKEETCH_.TTF \
41         $TEXMFLOCAL/other/SPANBBI_.INF \
42         $TEXMFLOCAL/other/SPANBB__.INF \
43         $TEXMFLOCAL/other/SPANBI__.INF \
44         $TEXMFLOCAL/other/SPANB___.INF \
45         $TEXMFLOCAL/other/Syriac__.inf \
46         $TEXMFLOCAL/other/Tallpaul.inf \
47         $TEXMFLOCAL/other/TEENSPIR.TTF \
48         $TEXMFLOCAL/other/WEBSTER_.INF
49
50 sed -i s/Map\ emerald.map//g $TEXMFLOCAL/web2c/updmap.cfg
51 sed -i '/^$/d' $TEXMFLOCAL/web2c/updmap.cfg
52 if [ ! -s $TEXMFLOCAL/web2c/updmap.cfg ] ; then
53         rm $TEXMFLOCAL/web2c/updmap.cfg
54 fi
55
56 rmdir --ignore-fail-on-non-empty $TEXMFLOCAL/fonts/map/dvips \
57                                 $TEXMFLOCAL/fonts/afm \
58                                 $TEXMFLOCAL/fonts/map \
59                                 $TEXMFLOCAL/fonts/tfm \
60                                 $TEXMFLOCAL/fonts/type1 \
61                                 $TEXMFLOCAL/fonts/vf \
62                                 $TEXMFLOCAL/tex/latex \
63                                 $TEXMFLOCAL/fonts \
64                                 $TEXMFLOCAL/tex \
65                                 $TEXMFLOCAL/other \
66                                 $TEXMFLOCAL/web2c/
67
68
69 mktexlsr $TEXMFLOCAL
70 updmap-sys