pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/mail/cyrus-imapd21 Actually warn about the IMAP direct...
details: https://anonhg.NetBSD.org/pkgsrc/rev/4c222b778981
branches: trunk
changeset: 478841:4c222b778981
user: jlam <jlam%pkgsrc.org@localhost>
date: Sat Jul 31 03:28:32 2004 +0000
description:
Actually warn about the IMAP directories if they can't be removed.
Removing directories happens at POST-DEINSTALL time, but the imapd.conf
file may be removed during the DEINSTALL stop, so we need to add the code
to remove the IMAP directories explicitly in the DEINSTALL step, as well.
diffstat:
mail/cyrus-imapd21/DEINSTALL | 29 +++++++++++++++++++++++------
1 files changed, 23 insertions(+), 6 deletions(-)
diffs (48 lines):
diff -r c3f6843c6c1d -r 4c222b778981 mail/cyrus-imapd21/DEINSTALL
--- a/mail/cyrus-imapd21/DEINSTALL Sat Jul 31 02:28:15 2004 +0000
+++ b/mail/cyrus-imapd21/DEINSTALL Sat Jul 31 03:28:32 2004 +0000
@@ -1,21 +1,38 @@
-# $NetBSD: DEINSTALL,v 1.2 2003/08/30 20:22:56 jlam Exp $
+# $NetBSD: DEINSTALL,v 1.3 2004/07/31 03:28:32 jlam Exp $
IMAPDCONF=@IMAPDCONF@
case ${STAGE} in
DEINSTALL)
if [ -f ${IMAPDCONF} ]; then
- imap_dirs=` \
+ IMAPDIRS=`
${AWK} '/configdirectory:/ { print $2 }; \
/partition-.*:/ { print $2 }; \
/sievedir:/ { print $2 }' \
- ${IMAPDCONF} \
- `
- for dir in ${imap_dirs}; do
+ ${IMAPDCONF} | ${SORT} -ur`
+ _IMAPDIRS=
+ for dir in ${IMAPDIRS}; do
+ ${RMDIR} -p ${dir} 2>/dev/null || ${TRUE}
if [ -d ${dir} ]; then
- ALL_DIRS="${ALL_DIRS} ${dir}"
+ _IMAPDIRS="${_IMAPDIRS} ${dir}"
fi
done
+ if [ -n "${_IMAPDIRS}" ]; then
+ ${CAT} << EOF
+===========================================================================
+If you won't be using ${PKGNAME} any longer, you may want to remove
+the following directories:
+
+EOF
+ for dir in ${_IMAPDIRS}; do
+ if [ -d "${dir}" ]; then
+ ${ECHO} " ${dir}"
+ fi
+ done
+ ${CAT} << EOF
+===========================================================================
+EOF
+ fi
fi
;;
esac
Home |
Main Index |
Thread Index |
Old Index