mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-30 01:15:52 +00:00
8f8d2bdf2a
- Bump PORTREVISION - Clean up pkg-deinstall: + remove an unnecessary variable + replace rmdir -p with two distinct rmdir calls since we do not want to delete $PKG_PREFIX too if it happens to be empty PR: ports/65918 Submitted by: maintainer
37 lines
927 B
Bash
37 lines
927 B
Bash
#!/bin/sh
|
|
#
|
|
# $FreeBSD$
|
|
#
|
|
|
|
PATH=/bin:/usr/bin:/usr/sbin
|
|
|
|
case $2 in
|
|
DEINSTALL)
|
|
cd ${PKG_PREFIX}/etc/squid || exit 1
|
|
for f in squid.conf mime.conf msntauth.conf; do
|
|
cmp -s -z ${f} ${f}.default && rm ${f}
|
|
done
|
|
;;
|
|
POST-DEINSTALL)
|
|
rmdir ${PKG_PREFIX}/etc/squid 2>/dev/null
|
|
rmdir ${PKG_PREFIX}/squid/cache 2>/dev/null
|
|
rmdir ${PKG_PREFIX}/squid/logs 2>/dev/null
|
|
rmdir ${PKG_PREFIX}/squid 2>/dev/null
|
|
echo "===> post-deinstallation information for $1"
|
|
echo ""
|
|
echo " Please note that $1 was not completely removed"
|
|
echo " from this system."
|
|
echo ""
|
|
echo " The cache and log directories, squid's user account,"
|
|
echo " and any modified configuration files have been preserved"
|
|
echo " in case you want to install an updated version of squid"
|
|
echo " on this system. You must remove them manually if you do"
|
|
echo " not want to use squid any longer."
|
|
echo ""
|
|
;;
|
|
*)
|
|
exit 64
|
|
;;
|
|
esac
|
|
exit 0
|