@@ -173,22 +173,32 @@ jobs:
173
173
steps :
174
174
- uses : actions/checkout@v3
175
175
- uses : DeterminateSystems/nix-installer-action@main
176
+
176
177
- name : Get Versions from Matrix Config
177
178
id : get_versions
178
179
run : |
179
- # Extract the versions from prepare.outputs.matrix_config
180
- echo "Versions: ${{ fromJson(needs.prepare.outputs.matrix_config).include }}" # Print the versions for debugging
181
- echo "versions=$(echo '${{ fromJson(needs.prepare.outputs.matrix_config).include }}' | jq -r 'map(.version) | join(\",\")')" >> $GITHUB_ENV
180
+ nix run nixpkgs#nushell -- -c '
181
+ # Extract the versions from prepare.outputs.matrix_config
182
+ let versions = ${{ fromJson(needs.prepare.outputs.matrix_config).include }} | get version
183
+ echo "Versions: $versions"
184
+
185
+ # Set the versions to an environment variable in GitHub Actions' environment
186
+ let versions_str = ($versions | join ",")
187
+ $"versions=$versions_str" | save --append $env.GITHUB_ENV
188
+ '
182
189
183
190
- name : Download Results Artifacts
184
191
run : |
185
- # Split the versions into a list and download each corresponding artifact
186
- for version in $(echo ${{ env.versions }} | tr "," "\n"); do
187
- artifact_name="merge_results-${version}"
188
- echo "Downloading artifact: $artifact_name"
189
- actions/download-artifact@v3
190
- with:
191
- name: $artifact_name
192
+ nix run nixpkgs#nushell -- -c '
193
+ let versions = env.versions | str split ","
194
+ foreach $version in $versions {
195
+ let artifact_name = "merge_results-$version"
196
+ echo "Downloading artifact: $artifact_name"
197
+ actions/download-artifact@v3
198
+ with:
199
+ name: $artifact_name
200
+ }
201
+ '
192
202
- name : Combine Results
193
203
id : combine
194
204
run : |
0 commit comments