#!/bin/sh
# $OpenBSD: DEINSTALL,v 1.4 2003/12/31 16:03:30 naddy Exp $
#
# Bitlbee de-installation script.

PATH=/bin:/usr/bin:/sbin:/usr/sbin
PREFIX=${PKG_PREFIX:-/usr/local}
DB_DIR=${DB_DIR}
CONFIG_DIR=${ETCDIR}
BITLBEEUSER=${BITLBEEUSER}
BITLBEEGROUP=${BITLBEEGROUP}

# the -c target now removes
if [ "${PKG_DELETE_EXTRA}" = Yes ]; then
    cat << EOF
+---------------
| To completely deinstall the bitlbee package you have to remove the
| bitlbee line from /etc/inetd.conf and restart inetd with:
|
|    # kill -HUP \`cat /var/run/inetd.pid\`
|
+---------------

EOF
else
    cat << EOF
+---------------
| To completely deinstall the bitlbee package you need to perform these
| steps as root:
|
|    # userdel $BITLBEEUSER
|    # groupdel $BITLBEEGROUP
|    # rm -rf $CONFIG_DIR
|    # rm -rf $DB_DIR
|
| You also have to remove the bitlbee line from /etc/inetd.conf and
| restart inetd with
|
|    # kill -HUP \`cat /var/run/inetd.pid\`
|
| Do not do this if you plan on re-installing bitlbee at some future
| time.
+---------------

EOF
fi
