Skip to content

Commit a71fbee

Browse files
committed
Testing upload actions
1 parent 42e21cf commit a71fbee

File tree

1 file changed

+50
-0
lines changed

1 file changed

+50
-0
lines changed

.github/workflows/toolkit-package.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: Download Toolkit Remix Package
2+
3+
on:
4+
push:
5+
branches: [main]
6+
7+
jobs:
8+
rtx-remix-windows-release:
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- name: Checkout repository
13+
uses: actions/checkout@v4
14+
15+
- name: Download package
16+
run: |
17+
# Get current commit SHA (first 8 characters)
18+
SHORT_SHA="97eb63e0"
19+
20+
echo "Current commit SHA: $SHORT_SHA"
21+
22+
# Download with original filename preserved
23+
curl -L -O -J "https://d1oqksizpb0e3d.cloudfront.net/rtx_remix@latest"
24+
25+
# Find the downloaded file
26+
DOWNLOADED_FILE=$(ls rtx_remix@*.zip 2>/dev/null | head -n 1)
27+
28+
if [[ -f "$DOWNLOADED_FILE" ]]; then
29+
echo "Downloaded file: $DOWNLOADED_FILE"
30+
31+
# Check if filename contains the commit SHA
32+
if [[ "$DOWNLOADED_FILE" == *"$SHORT_SHA"* ]]; then
33+
echo "✅ Filename contains commit SHA $SHORT_SHA - will upload"
34+
echo "SHOULD_UPLOAD=true" >> $GITHUB_ENV
35+
echo "FILENAME=$DOWNLOADED_FILE" >> $GITHUB_ENV
36+
else
37+
echo "❌ Filename does not contain commit SHA $SHORT_SHA - skipping upload"
38+
echo "SHOULD_UPLOAD=false" >> $GITHUB_ENV
39+
fi
40+
else
41+
echo "❌ No rtx_remix@*.zip file found"
42+
echo "SHOULD_UPLOAD=false" >> $GITHUB_ENV
43+
fi
44+
45+
- name: Upload artifact
46+
if: env.SHOULD_UPLOAD == 'true'
47+
uses: actions/upload-artifact@v4
48+
with:
49+
name: rtx-remix-package
50+
path: ${{ env.FILENAME }}

0 commit comments

Comments
 (0)