From: Ian Kelling Date: Mon, 1 May 2023 02:29:20 +0000 (-0400) Subject: minor fix X-Git-Url: https://iankelling.org/git/?a=commitdiff_plain;h=957654ed1672c7ca933583549b9d8e9f37b1c802;p=distro-setup minor fix --- diff --git a/system-status b/system-status index cd603ca..7d5567d 100755 --- a/system-status +++ b/system-status @@ -140,13 +140,13 @@ write-status() { # PS4='+ $(date "+%2N") ' # allow failure in case there are no snapshots yet. # shellcheck disable=SC2012 - shopt -u nullglob - files=($btrbk_root/$vol.20*) shopt -s nullglob - snaps=() - if (( ${#files[@]} )); then - snaps=($(ls -1avdr "${files[@]}" 2>/dev/null |head -n1 || : )) + files=($btrbk_root/$vol.20*) + shopt -u nullglob + if (( ! ${#files[@]} )); then + continue fi + snaps=($(ls -1avdr "${files[@]}" 2>/dev/null |head -n1 || : )) now=$EPOCHSECONDS maxtime=0 for s in ${snaps[@]}; do