From f2335894a40da8b02e756d19293eee840714bf63 Mon Sep 17 00:00:00 2001 From: boa-z Date: Sat, 2 Nov 2024 23:33:38 +0800 Subject: [PATCH] macos build action Create the DMG file with Applications shortcut --- .github/workflows/main.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index a28ca51..26b1ba3 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -27,16 +27,16 @@ jobs: - name: Build Flutter macOS App run: flutter build macos --release - - # Step 4: Create the DMG file + # Step 3: Create the DMG file - name: Create DMG run: | mkdir -p dist - hdiutil create -volname "venera" -srcfolder build/macos/Build/Products/Release/venera.app -ov -format UDZO "dist/venera.dmg" + mkdir -p dist/dmg_contents + cp -R build/macos/Build/Products/Release/venera.app dist/dmg_contents/ + ln -s /Applications dist/dmg_contents/Applications + hdiutil create -volname "venera" -srcfolder dist/dmg_contents -ov -format UDZO "dist/venera.dmg" - - - # Step 8: Attach and upload artifacts (optional) + # Step 4: Attach and upload artifacts (optional) - name: Upload DMG uses: actions/upload-artifact@v3 with: