Skip to content

Commit 41448b8

Browse files
authored
ci.yml: Update MODULE_VER creation logic to use bash splitting (#117)
1 parent 1a5925b commit 41448b8

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

.github/workflows/ci.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,8 @@ jobs:
144144
DEP_VER=$(yq ".spack.packages.\"$DEP\".require[0] | match(\"^@(?:git.)?([^=]*)\").captures[0].string" spack.yaml)
145145
fi
146146
147-
MODULE_VER=$(yq ".spack.modules.default.tcl.projections.\"$DEP\" | split(\"/\") | .[1]" spack.yaml)
147+
MODULE_NAME=$(yq ".spack.modules.default.tcl.projections.\"$DEP\"" spack.yaml)
148+
MODULE_VER="${MODULE_NAME#*/}" # Get 'version' from 'name/version' module, even if version contains '/'
148149
149150
if [[ "$DEP_VER" != "$MODULE_VER" ]]; then
150151
echo "::error::$DEP: Version of dependency and projection do not match ($DEP_VER != $MODULE_VER)"

0 commit comments

Comments
 (0)