Skip to content

Commit 54752d0

Browse files
committed
ci: try fix artifact upload path
1 parent b1882fd commit 54752d0

1 file changed

Lines changed: 23 additions & 1 deletion

File tree

.github/workflows/build-and-upload-aml.yml

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,8 +90,30 @@ jobs:
9090
name: aml-all
9191
path: ./
9292

93+
- name: Find per-platform directory
94+
id: find
95+
run: |
96+
set -euo pipefail
97+
PLATFORM="${{ matrix.platform }}"
98+
echo "Searching for platform directory: $PLATFORM"
99+
# Try several candidate locations that may exist depending on how the artifact was uploaded
100+
if [ -d "aml-all/artifacts/$PLATFORM" ]; then
101+
echo "Found at aml-all/artifacts/$PLATFORM"
102+
echo "path=aml-all/artifacts/$PLATFORM" >> $GITHUB_OUTPUT
103+
elif [ -d "artifacts/$PLATFORM" ]; then
104+
echo "Found at artifacts/$PLATFORM"
105+
echo "path=artifacts/$PLATFORM" >> $GITHUB_OUTPUT
106+
elif [ -d "$PLATFORM" ]; then
107+
echo "Found at $PLATFORM"
108+
echo "path=$PLATFORM" >> $GITHUB_OUTPUT
109+
else
110+
echo "platform_path not found for $PLATFORM"
111+
echo "path=" >> $GITHUB_OUTPUT
112+
fi
113+
93114
- name: Upload per-platform artifact
115+
if: steps.find.outputs.path != ''
94116
uses: actions/upload-artifact@v4
95117
with:
96118
name: ${{ matrix.platform }}
97-
path: aml-all/artifacts/${{ matrix.platform }}
119+
path: ${{ steps.find.outputs.path }}

0 commit comments

Comments
 (0)