From: Joerg Jaspert Date: Tue, 29 Dec 2015 14:32:56 +0000 (+0100) Subject: Remember if a file is not on snapshot, don't try every run X-Git-Url: https://git.decadent.org.uk/gitweb/?a=commitdiff_plain;h=460b431da971dc01d047dcefd2e146c6d42c0195;p=dak.git Remember if a file is not on snapshot, don't try every run --- diff --git a/scripts/debian/link_morgue.sh b/scripts/debian/link_morgue.sh index 83d4aeb2..b4dec532 100755 --- a/scripts/debian/link_morgue.sh +++ b/scripts/debian/link_morgue.sh @@ -85,6 +85,11 @@ cd "${PROCESSDIR}" log "Processing ${PROCESSDIR}" find ${PROCESSDIR} -type f | while read mfile; do + if [[ -f ${mfile}.nosnapshot ]]; then + # We know this file does not exist on snapshot, don't check again + continue + fi + # Get the files sha1sum mshasum=$(sha1sum ${mfile}) mshasum=${mshasum%% *} @@ -111,6 +116,8 @@ while read mfile; do # Yay for tons of dangling symlinks, but when this is done a rsync # will run and transfer the whole shitload of links over to the morgue host. ln -sf "${FARMBASE}/${LVL1}/${LVL2}/${mshasum}" "${mfile}" + else + touch "${mfile}.nosnapshot" fi fi done # for mfile in...