1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-24 00:45:52 +00:00
freebsd-ports/security/sfs/pkg-deinstall
Matthew N. Dodd f36fcd52f2 - Update documentation.
- Sanitize install script.
- Bump PORTREVISION.

Submitted by:		MAINTAINER
2002-07-12 05:31:41 +00:00

35 lines
914 B
Bash

#!/bin/sh
if [ -n "${PACKAGE_BUILDING}" ]; then
exit 0
fi
if [ "$2" != "POST-DEINSTALL" ]; then
exit 0
fi
USER=sfs
GROUP=sfs
PW=/usr/sbin/pw
SFSDIR=/var/spool/sfs
if ${PW} groupshow "${GROUP}" >/dev/null 2>&1; then
echo "If you're done with SFS permanently, delete the sfs group manually: pw groupdel ${GROUP}" | fmt
fi
if ${PW} usershow "${USER}" >/dev/null 2>&1; then
echo
echo "If you're done with SFS permanently, delete the sfs user manually: pw userdel ${USER}" | fmt
fi
if [ -d "$PKG_PREFIX/etc/sfs" ] && ! rmdir $PKG_PREFIX/etc/sfs 2>/dev/null; then
echo
echo "You may wish to investigate the contents of $PKG_PREFIX/etc/sfs and delete the directory if you're done with SFS permanently." | fmt
fi
if [ -d "$SFSDIR" ] && ! rmdir $SFSDIR 2>/dev/null; then
echo
echo "You may wish to investigate the contents of $SFSDIR and delete the directory if you're done with SFS permanently." | fmt
fi