@@ -156,15 +156,47 @@ jobs:
156156 TAURI_SIGNING_PRIVATE_KEY : ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
157157 TAURI_SIGNING_PRIVATE_KEY_PASSWORD : ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
158158
159+ - name : Resolve artifact paths
160+ id : paths
161+ shell : bash
162+ run : |
163+ set -euo pipefail
164+
165+ bundle_dir=""
166+ if [ -d "src-tauri/target/${{ matrix.target }}/release/bundle" ]; then
167+ bundle_dir="src-tauri/target/${{ matrix.target }}/release/bundle"
168+ elif [ -d "src-tauri/target/release/bundle" ]; then
169+ bundle_dir="src-tauri/target/release/bundle"
170+ fi
171+
172+ if [ -z "$bundle_dir" ]; then
173+ echo "No bundle directory found for target ${{ matrix.target }}"
174+ find src-tauri/target -maxdepth 6 -type d -name bundle -print || true
175+ exit 1
176+ fi
177+
178+ echo "bundle_dir=$bundle_dir" >> "$GITHUB_OUTPUT"
179+
159180 - name : Collect updater metadata
160181 shell : bash
182+ env :
183+ TAURI_SIGNING_PRIVATE_KEY : ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
161184 run : |
162185 set -euo pipefail
163186 mkdir -p updater-json
164187
165- json_file="$(find src-tauri/target/${{ matrix.target }} -type f -name latest.json | head -n 1)"
188+ if [ -z "${TAURI_SIGNING_PRIVATE_KEY:-}" ]; then
189+ echo "TAURI_SIGNING_PRIVATE_KEY is empty. Updater artifacts (latest.json) will not be generated."
190+ exit 1
191+ fi
192+
193+ json_file="$(
194+ find "${{ steps.paths.outputs.bundle_dir }}" -type f -name latest.json 2>/dev/null | head -n 1 || true
195+ )"
166196 if [ -z "$json_file" ]; then
167197 echo "No latest.json found for target ${{ matrix.target }}"
198+ echo "Searched in: ${{ steps.paths.outputs.bundle_dir }}"
199+ find "${{ steps.paths.outputs.bundle_dir }}" -maxdepth 4 -type f -print || true
168200 exit 1
169201 fi
170202
@@ -174,7 +206,7 @@ jobs:
174206 uses : actions/upload-artifact@v4
175207 with :
176208 name : bundle-${{ matrix.target }}
177- path : src-tauri/target/ ${{ matrix.target }}/release/bundle /**/*
209+ path : ${{ steps.paths.outputs.bundle_dir }}/**/*
178210 if-no-files-found : error
179211
180212 - name : Upload updater metadata artifact
0 commit comments