From e55aec4f068bf444f646656b75b58dedf7d9c8a1 Mon Sep 17 00:00:00 2001 From: Giorgio Bolzon Date: Thu, 14 May 2026 14:55:05 +0200 Subject: [PATCH] Using second time of a list instead of the first one. Because in case of weekly files, the first one does not guarantee to have the same time when we generate it with ogstm.xx or with weekly_averager.py --- archive/tar_avedir.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/archive/tar_avedir.sh b/archive/tar_avedir.sh index 9646ea2..6118d9f 100755 --- a/archive/tar_avedir.sh +++ b/archive/tar_avedir.sh @@ -48,8 +48,8 @@ date # get varlist cd ${INPUT_AVEDIR} -FIRST_TIME=`ls ave*${REF_VAR}.nc | head -1 | cut -c 1-22` -ls ${FIRST_TIME}*nc | cut -d "." -f 3 > $HERE/allvarlist.txt +SECOND_TIME=`ls ave*${REF_VAR}.nc | head -2 | tail -1 | cut -c 1-22` +ls ${SECOND_TIME}*nc | cut -d "." -f 3 > $HERE/allvarlist.txt # creating tars