From 2299a32c2bc3979b1e0ef88bc39d2b4c77480679 Mon Sep 17 00:00:00 2001 From: Ken Fallon Date: Sun, 3 Mar 2024 13:50:51 +0100 Subject: [PATCH] Checks for host with id of 0 in the reserve queue and manually post them to the main queue --- bin/rename-reserve.bash | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/bin/rename-reserve.bash b/bin/rename-reserve.bash index 02a70be..179ed7f 100755 --- a/bin/rename-reserve.bash +++ b/bin/rename-reserve.bash @@ -16,6 +16,13 @@ do echo "ERROR: \"${shownotes}\" not found" exit 1 fi + host_id="$( jq --raw-output '.host.Host_ID' "${shownotes}" )" + if [ "${host_id}" -eq "0" ] + then + echo "ERROR: New host detected \"${host_id}\" post the first show to the regular queue." + exit 1 + fi + metadata_url="$( jq --raw-output '.metadata.url' "${shownotes}" )" if [ -n "${metadata_url}" ] then