From 1d6fd01c9e9e44ad68bd79c0e8a4befc686f6f03 Mon Sep 17 00:00:00 2001 From: Alex Iribarren <Alex.Iribarren@cern.ch> Date: Sat, 9 Mar 2024 11:20:52 +0100 Subject: [PATCH] Stop warning, just delete the .~tmp~ directories --- rsync/runsync.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rsync/runsync.sh b/rsync/runsync.sh index bbec835..952cab2 100755 --- a/rsync/runsync.sh +++ b/rsync/runsync.sh @@ -98,14 +98,14 @@ EOF fi RET=$? -# Check if there are leftover tmp directories, which will probably have to be deleted manually +# Check if there are leftover tmp directories, which will have to be deleted. # For the ones that use quick-fedora-mirror, we kind of have to guess where the files go. if [[ "${TOOL}" == "quick-fedora-mirror" ]]; then BASE="/repo/${NOMAD_TASK_NAME#prod_rsync_}" else BASE="/repo" fi -[[ -d $BASE ]] && find $BASE -type d -name '.~tmp~' -exec echo 'Warning: tmp directory detected: {}' \; +[[ -d $BASE ]] && find $BASE -type d -name '.~tmp~' -exec rm -rfv {} \; if [[ $RET -ne 0 ]]; then cat << EOF | error | tee $OUTPUT -- GitLab