Skip to content

Commit ddce972

Browse files
committed
fixed problem with set path step
1 parent 286bcca commit ddce972

File tree

1 file changed

+13
-8
lines changed

1 file changed

+13
-8
lines changed

.github/workflows/release.yaml

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -52,29 +52,34 @@ jobs:
5252
test: false
5353
stack-build-arguments: --copy-bins --ghc-options="-O2"
5454

55-
- name: Set binary path name
56-
id: binarypath
57-
run: for TOOL in pileupCaller vcf2eigenstrat genoStats; do
55+
- name: Set binary path names
56+
id: binarypaths
57+
run: |
58+
binaries=()
59+
for TOOL in pileupCaller vcf2eigenstrat genoStats; do
5860
if [ "$RUNNER_OS" == "Windows" ]; then
5961
newEXE="$TOOL-$RUNNER_OS.exe"
6062
else
6163
newEXE="$TOOL-$RUNNER_OS-$RUNNER_ARCH"
6264
fi
6365
currentEXE="${{ steps.stack.outputs.local-bin }}/$TOOL"
64-
mv $currentEXE $newEXE
65-
echo "BINARY_PATH=$newEXE" >> $GITHUB_OUTPUT
66+
mv "$currentEXE" "$newEXE"
67+
binaries+=("$newEXE")
6668
done
69+
# join with commas for release-action
70+
binary_paths=$(printf "%s," "${binaries[@]}")
71+
binary_paths=${binary_paths%,}
72+
echo "BINARY_PATHS=$binary_paths" >> "$GITHUB_OUTPUT"
6773
shell: bash
6874

69-
- name: Upload Release Asset
70-
id: upload-release-asset
75+
- name: Upload Release Assets
7176
uses: ncipollo/release-action@v1
7277
with:
7378
name: Release ${{ github.ref_name }}
7479
draft: true
7580
allowUpdates: true
7681
artifactErrorsFailBuild: true
77-
artifacts: ${{ steps.binarypath.outputs.BINARY_PATH }}
82+
artifacts: ${{ steps.binarypaths.outputs.BINARY_PATHS }}
7883
artifactContentType: application/octet-stream
7984

8085
# build_centos_artifact:

0 commit comments

Comments
 (0)