Skip to content

Commit 884d75c

Browse files
committed
ci: fix targeted macos x64 asset upload
1 parent f3dbecf commit 884d75c

1 file changed

Lines changed: 17 additions & 5 deletions

File tree

.github/workflows/release.yml

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -259,11 +259,23 @@ jobs:
259259
run: |
260260
TAG="${{ steps.get-tag.outputs.tag }}"
261261
BUNDLE_DIR="src-tauri/target/${{ matrix.target }}/release/bundle"
262-
shopt -s globstar nullglob
263-
assets=(
264-
"$BUNDLE_DIR"/**/*.dmg
265-
"$BUNDLE_DIR"/**/*.app.tar.gz
266-
"$BUNDLE_DIR"/**/*.sig
262+
MACOS_DIR="$BUNDLE_DIR/macos"
263+
if [ -f "$MACOS_DIR/lovcode.app.tar.gz" ]; then
264+
mv "$MACOS_DIR/lovcode.app.tar.gz" "$MACOS_DIR/lovcode_x64.app.tar.gz"
265+
fi
266+
if [ -f "$MACOS_DIR/lovcode.app.tar.gz.sig" ]; then
267+
mv "$MACOS_DIR/lovcode.app.tar.gz.sig" "$MACOS_DIR/lovcode_x64.app.tar.gz.sig"
268+
fi
269+
270+
assets=()
271+
while IFS= read -r asset; do
272+
assets+=("$asset")
273+
done < <(
274+
find "$BUNDLE_DIR" -type f \( \
275+
-name '*.dmg' -o \
276+
-name '*.app.tar.gz' -o \
277+
-name '*.sig' \
278+
\) -print
267279
)
268280
269281
if [ "${#assets[@]}" -eq 0 ]; then

0 commit comments

Comments
 (0)