1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-01 22:05:08 +00:00
freebsd-ports/print/yatex/files/DEINSTALL.tmpl
Jun Kuriyama 05ec898c2c Yet Another LaTeX mode on Emacs (including another html-mode)
PR:		ports/4412
Submitted by:	Satoshi Taoka <taoka@infonets.hiroshima-u.ac.jp>
1998-08-14 00:16:07 +00:00

33 lines
936 B
Bash

#!/bin/sh
pkgname=$1
CP=${CP:-%CP%}
ECHO=${ECHO:-%ECHO%}
GREP=${GREP:-%GREP%}
RM=${RM:-%RM%}
SED=${SED:-%SED%}
infodir=${INFODIR:-%INFODIR%}
infofiles=${INFOFILES:-%INFOFILES%}
elispdir=${ELISPDIR:-%ELISPDIR%}
OptionStart=";;; configuration options for ${pkgname}"
OptionEnd=";;; End of configuration options for ${pkgname}"
if [ "X$2" = X"DEINSTALL" ]; then
${ECHO} "Deleting entry for \"${pkgname}\" from ${infodir}/dir"
for file in `echo ${infofiles} | ${SED} "s,:, ,g"`; do
install-info --delete ${infodir}/${file} ${infodir}/dir
done
if [ "`grep \"^${OptionStart}\" ${elispdir}/site-start.el`" ]; then
${ECHO} "Deleting entry for \"${pkgname}\" from ${elispdir}/site-start.el"
${SED} -e "/^${OptionStart}/,/^${OptionEnd}/d" \
${elispdir}/site-start.el > ${elispdir}/site-start.el.bak
${CP} ${elispdir}/site-start.el.bak ${elispdir}/site-start.el
${RM} ${elispdir}/site-start.el.bak
fi
else
exit 0
fi