Skip to content

Commit cbc34bb

Browse files
committed
build-lxd.yml: Don't perform NC updates if installed NC version is newer than latest supported version
1 parent 5d5e554 commit cbc34bb

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

.github/workflows/build-lxd.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -321,7 +321,9 @@ jobs:
321321
sudo "$LXC" exec ncp -- bash -c "DBG=x ncp-update ${UPDATE_ARGS[*]}"
322322
sudo "$LXC" exec ncp -- /usr/local/bin/ncc status
323323
324-
if [[ "$current_nc_version" =~ "$latest_nc_version".* ]]
324+
latest_build="${latest_nc_version#*.}"
325+
latest_build="${latest_build#*.}"
326+
if [[ "$current_nc_version" =~ "$latest_nc_version".* ]] || { [[ "^${latest_nc_version}" =~ "${current_nc_version%.*}".* ]] && [[ "${current_nc_version##*.}" -lt "${latest_build}" ]]; }
325327
then
326328
echo "Nextcloud is up to date - skipping NC update test."
327329
else

0 commit comments

Comments
 (0)