Merge branch '350-build-system-handle-empty-variants-blocks' into 'master'

Resolve "build-system: handle empty variants blocks"

Closes #350

See merge request Pmodules/src!347

(cherry picked from commit ffbc6292eb)

047d55d8 build-system: bugfix: handle empty variants

Co-authored-by: gsell <achim.gsell@psi.ch>
This commit is contained in:
2024-09-02 18:25:20 +02:00
parent 864a16ab45
commit e30338240a
+5
View File
@@ -818,6 +818,11 @@ build_modules_yaml_v1(){
local -- type_of_key=''
type_of_key=$( ${yq} -e ".variants | type" 2>/dev/null <<<"${yaml_input}")
if [[ "${type_of_key}" == '!!null' ]]; then
result=''
n=0
return 0
fi
if [[ "${type_of_key}" != '!!seq' ]]; then
die_invalid_variants_block "${name}" "${version}" \
"${type_of_key}"