mirror of
https://github.com/edgelesssys/constellation.git
synced 2025-01-12 16:09:39 -05:00
ci: fix ccm build when no new version are found
Previous output of findvers.sh would be [""] in case no version were found, now the output is []. Also, GitHub cannot handle empty arrays in the matrix field, so we add an if and check if the array is empty. Signed-off-by: Paul Meyer <49727155+katexochen@users.noreply.github.com>
This commit is contained in:
parent
47fc676927
commit
abd5cdf362
@ -81,4 +81,5 @@ for major in "${allMajorVersions[@]}"; do
|
||||
versionsToBuild+=("${latest}")
|
||||
done
|
||||
|
||||
printf '%s\n' "${versionsToBuild[@]}" | jq -R | jq -sc
|
||||
# Print one elem per line | quote elems | create array | remove empty elems and print compact.
|
||||
printf '%s' "${versionsToBuild[@]}" | jq -R | jq -s | jq -c 'map(select(length > 0))'
|
||||
|
2
.github/workflows/build-ccm-gcp.yml
vendored
2
.github/workflows/build-ccm-gcp.yml
vendored
@ -52,6 +52,8 @@ jobs:
|
||||
echo "latest=${lastest}" | tee -a "$GITHUB_OUTPUT"
|
||||
|
||||
build-ccm-gcp:
|
||||
# matrix cannot handle empty lists
|
||||
if: needs.find-ccm-versions.outputs.versions != '[]'
|
||||
runs-on: ubuntu-22.04
|
||||
permissions:
|
||||
contents: read
|
||||
|
Loading…
Reference in New Issue
Block a user