Skip to content

Commit

Permalink
CI: Ensure finding no pattern match results in an empty string
Browse files Browse the repository at this point in the history
If no pattern match is found, which we expect for Qt x86 builds, then
return an empty string by enabling the nullglob option.

Additionally, add quotes for paths for safety and fix the for loop array
syntax.
  • Loading branch information
RytoEX committed Sep 5, 2024
1 parent 077abdb commit 45b7d2c
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -607,6 +607,7 @@ jobs:
run: |
: Package Windows dependencies
shopt -s extglob
shopt -s nullglob
for arch in x64 x86; do
_temp=$(mktemp -d)
Expand All @@ -624,8 +625,8 @@ jobs:
mv windows-deps-${{ steps.metadata.outputs.version }}-${arch}.zip ${GITHUB_WORKSPACE}
files=("${GITHUB_WORKSPACE}"/qt6-windows-"${arch}"-!(*-@(Debug|RelWithDebInfo|Release|MinSizeRel))/*.zip)
for artifact in ${files}; do
mv ${artifact} ${GITHUB_WORKSPACE}
for artifact in "${files[@]}"; do
mv "${artifact}" "${GITHUB_WORKSPACE}"
done
popd > /dev/null
done
Expand Down

0 comments on commit 45b7d2c

Please sign in to comment.