From 5f32ca4cdce5faf0833f1203e17368036a7b3984 Mon Sep 17 00:00:00 2001 From: Malte Date: Thu, 29 Oct 2020 06:19:20 +0100 Subject: [PATCH] fixes hard-wired created date (https://github.com/eikek/docspell/pull/403#discussion_r513790807) --- tools/consumedir-cleaner/consumedir-cleaner.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/consumedir-cleaner/consumedir-cleaner.sh b/tools/consumedir-cleaner/consumedir-cleaner.sh index 458f5329..1e8c2574 100755 --- a/tools/consumedir-cleaner/consumedir-cleaner.sh +++ b/tools/consumedir-cleaner/consumedir-cleaner.sh @@ -146,7 +146,7 @@ do rm "$tmp_filepath" else created=$(echo $curl_result | jq -r ".items[0].created") - cur_dir="$ds_archive_path/$(date -d @$(echo "(1603892183000+500)/1000" | bc) +%Y-%m + cur_dir="$ds_archive_path/$(date -d @$(echo "($created+500)/1000" | bc) +%Y-%m )" echo "... moving to archive by month added ('$cur_dir')" mkdir -p "$cur_dir"