From 68a4e44c611a42dca1591835df4cf545a2ce6d59 Mon Sep 17 00:00:00 2001 From: RandomNinjaAtk Date: Mon, 11 Jul 2022 16:45:21 +0000 Subject: [PATCH] 1.0.141 - Delete empty twice to get all sub directories --- root/scripts/download.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/root/scripts/download.sh b/root/scripts/download.sh index 7bfee2e..9425033 100644 --- a/root/scripts/download.sh +++ b/root/scripts/download.sh @@ -1,5 +1,5 @@ #!/usr/bin/env bash -scriptVersion="1.0.140" +scriptVersion="1.0.141" lidarrUrlBase="$(cat /config/config.xml | xq | jq -r .Config.UrlBase)" if [ "$lidarrUrlBase" = "null" ]; then lidarrUrlBase="" @@ -608,6 +608,7 @@ DownloadProcess () { log ":: $processNumber of $wantedListAlbumTotal :: $lidarrArtistNameSanitized :: $lidarrAlbumTitle :: Consolidating files to single folder" find "/downloads/lidarr-extended/incomplete" -type f -exec mv "{}" /downloads/lidarr-extended/incomplete/ \; find /downloads/lidarr-extended/incomplete -mindepth 1 -type d -empty -exec rm -rf "{}" \; &>/dev/null + find /downloads/lidarr-extended/incomplete -mindepth 1 -type d -empty -exec rm -rf "{}" \; &>/dev/null # Check download for required quality (checks based on file extension) DownloadQualityCheck "/downloads/lidarr-extended/incomplete" "$2"