Updated 'future_upload' in 'check_uploads'

This commit is contained in:
Dave Morriss 2025-01-01 18:16:35 +00:00
parent a3c8586730
commit 4feae03fee

View File

@ -13,9 +13,9 @@
# NOTES: Contains methods from 'delete_uploaded' and 'weekly_upload' as # NOTES: Contains methods from 'delete_uploaded' and 'weekly_upload' as
# well as 'update_state' # well as 'update_state'
# AUTHOR: Dave Morriss (djm), Dave.Morriss@gmail.com # AUTHOR: Dave Morriss (djm), Dave.Morriss@gmail.com
# VERSION: 0.0.15 # VERSION: 0.0.16
# CREATED: 2021-01-07 12:11:02 # CREATED: 2021-01-07 12:11:02
# REVISION: 2024-07-29 23:17:45 # REVISION: 2025-01-01 11:48:40
# #
#=============================================================================== #===============================================================================
@ -26,7 +26,7 @@ SCRIPT=${0##*/}
STDOUT="/dev/fd/2" STDOUT="/dev/fd/2"
VERSION="0.0.15" VERSION="0.0.16"
# #
# Load library functions # Load library functions
@ -51,13 +51,24 @@ check_uploads () {
# #
# Look for files called hpr1234.flac and so on. Don't bother with the # Look for files called hpr1234.flac and so on. Don't bother with the
# hpr1234_source.flac one. As soon as a file is missing return with false. # hpr1234_source.flac one. As soon as a file is missing return with false.
# 2025-01-01: Dropped 'spx' from the list
# #
for suff in flac mp3 ogg opus spx wav; do for suff in flac mp3 ogg opus wav; do
if [[ ! -e $UPLOADS/$prefix.$suff ]]; then if [[ ! -e $UPLOADS/$prefix.$suff ]]; then
return 1 return 1
fi fi
done done
#
# Transcripts are (currently) in a sub-directory with the same name as the
# IA item. We only cater for two types as of 2025.
#
for suff in txt srt; do
if [[ ! -e $UPLOADS/$prefix/$prefix.$suff ]]; then
return 1
fi
done
return 0 return 0
} }