summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xmove-home-litter6
1 files changed, 6 insertions, 0 deletions
diff --git a/move-home-litter b/move-home-litter
index 5f3eba6..ad16c38 100755
--- a/move-home-litter
+++ b/move-home-litter
@@ -33,6 +33,12 @@ YESTERDAY="$(date -d '1 day ago' '+%F')"
TGT="$TGTDIR/$YESTERDAY"
cd "$BASE"
+
+if ! [ -e "$WHITELIST" ] ; then
+ echo >&2 "You need to set up a whitelist of files to keep in $WHITELIST."
+ exit 1
+fi
+
mkdir -p "$TGT"
find -mindepth 1 -maxdepth 1 ! -name '.*' -printf '%f\0' |