#!/bin/sh
# This script checks if the cache directory is empty
#
# TODO: might exclude obsolete files from check, so it returns false/1 in case of upgrades.

CACHE_DIR=/var/cache/apt/apt-file

if [ -z "$(find $CACHE_DIR -mindepth 1 -not -name '*tmp')" ]; then
	exit 0
fi

# Cache is not empty
exit 1
