summaryrefslogtreecommitdiff
path: root/mail/cyrus-imapd23/DEINSTALL
diff options
context:
space:
mode:
Diffstat (limited to 'mail/cyrus-imapd23/DEINSTALL')
-rw-r--r--mail/cyrus-imapd23/DEINSTALL38
1 files changed, 38 insertions, 0 deletions
diff --git a/mail/cyrus-imapd23/DEINSTALL b/mail/cyrus-imapd23/DEINSTALL
new file mode 100644
index 00000000000..1cc436e409a
--- /dev/null
+++ b/mail/cyrus-imapd23/DEINSTALL
@@ -0,0 +1,38 @@
+# $NetBSD: DEINSTALL,v 1.1.1.1 2010/02/11 08:27:09 obache Exp $
+
+IMAPDCONF=@IMAPDCONF@
+
+case ${STAGE} in
+DEINSTALL)
+ if [ -f ${IMAPDCONF} ]; then
+ IMAPDIRS=`
+ ${AWK} '/configdirectory:/ { print $2 }; \
+ /partition-.*:/ { print $2 }; \
+ /sievedir:/ { print $2 }' \
+ ${IMAPDCONF} | ${SORT} -ur`
+ _IMAPDIRS=
+ for dir in ${IMAPDIRS}; do
+ ${RMDIR} -p ${dir} 2>/dev/null || ${TRUE}
+ if [ -d ${dir} ]; then
+ _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