Fix for new OS builds to update properly

This commit is contained in:
Aaron Dewes 2022-02-28 22:38:13 +01:00
parent 4ff6fc3b55
commit 81a97d8c43

View File

@ -40,6 +40,11 @@ main () {
local external_version=$(cat "${CITADEL_ROOT}/info.json" | jq -r .version | cut -d "-" -f "1") local external_version=$(cat "${CITADEL_ROOT}/info.json" | jq -r .version | cut -d "-" -f "1")
local sd_version=$(cat "${SD_CITADEL_ROOT}/info.json" | jq -r .version | cut -d "-" -f "1") local sd_version=$(cat "${SD_CITADEL_ROOT}/info.json" | jq -r .version | cut -d "-" -f "1")
if [[ "${external_version}" == "0.5"* ]]; then
echo "External storage is on a pre version number reset version, updating to the latest version."
"${CITADEL_ROOT}/scripts/update/update" --path "${SD_CITADEL_ROOT}"
fi
if ! check_semver_range ">${external_version}" "${sd_version}"; then if ! check_semver_range ">${external_version}" "${sd_version}"; then
echo "No, SD version is not newer, exiting." echo "No, SD version is not newer, exiting."
exit 0 exit 0