#!/bin/sh

set -e

dpkg-maintscript-helper rm_conffile /etc/dbus-1/system.d/org.debian.AptXapianIndex.conf 0.46 apt-xapian-index -- "$@"
dpkg-maintscript-helper rm_conffile /etc/bash_completion.d/axi-cache 0.47+nmu2~ apt-xapian-index -- "$@"

if [ "$1" = "remove" -o "$1" = "purge" ]; then
	echo "Removing index /var/lib/apt-xapian-index..."
	rm -rf /var/cache/apt-xapian-index
fi

if [ "$1" = "remove" -o "$1" = "purge" ]; then
	rm -f /usr/share/apt-xapian-index/plugins/*.pyc
fi

#DEBHELPER#

exit 0
