diff options
Diffstat (limited to 'security/drweb-sendmail/pkg-deinstall')
-rw-r--r-- | security/drweb-sendmail/pkg-deinstall | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/security/drweb-sendmail/pkg-deinstall b/security/drweb-sendmail/pkg-deinstall new file mode 100644 index 000000000000..fe71e9e62b5e --- /dev/null +++ b/security/drweb-sendmail/pkg-deinstall @@ -0,0 +1,22 @@ +#!/bin/sh +# $FreeBSD$ +# + +if [ "$2" != "POST-DEINSTALL" ]; then + exit 0 +fi + +USER=drweb +ex=0 + +if pw usershow "${USER}" 2>/dev/null 1>&2; then + if pw userdel ${USER}; then + echo "Delete user/group \"${USER}\"." + else + echo "Deleting user/group \"${USER}\" failed..." + ex=1 + fi +fi + +[ "$ex" = "1" ] && exit 1 +exit 0 |