diff --git a/.github/actions/package/macos/action.yml b/.github/actions/package/macos/action.yml index 1693ca21b..af941b59d 100644 --- a/.github/actions/package/macos/action.yml +++ b/.github/actions/package/macos/action.yml @@ -91,17 +91,35 @@ runs: --password '${{ inputs.apple-notarize-password }}' xcrun stapler staple "Prism Launcher.app" + rm "../PrismLauncher.zip" else echo ":warning: Skipping notarization as credentials are not present." >> $GITHUB_STEP_SUMMARY fi - ditto -c -k --sequesterRsrc --keepParent "Prism Launcher.app" ../PrismLauncher.zip + + - name: Create DMG + shell: bash + env: + INSTALL_DIR: install + run: | + cd ${{ env.INSTALL_DIR }} + + mkdir -p src + cp -R "Prism Launcher.app" src/ + + ln -s /Applications src/ + + hdiutil create \ + -volname "Prism Launcher ${{ inputs.version }}" \ + -srcfolder src \ + -ov -format ULMO \ + "../PrismLauncher.dmg" - name: Make Sparkle signature shell: bash run: | if [ '${{ inputs.sparkle-ed25519-key }}' != '' ]; then echo '${{ inputs.sparkle-ed25519-key }}' > ed25519-priv.pem - signature=$(/opt/homebrew/opt/openssl@3/bin/openssl pkeyutl -sign -rawin -in ${{ github.workspace }}/PrismLauncher.zip -inkey ed25519-priv.pem | openssl base64 | tr -d \\n) + signature=$(/opt/homebrew/opt/openssl@3/bin/openssl pkeyutl -sign -rawin -in ${{ github.workspace }}/PrismLauncher.dmg -inkey ed25519-priv.pem | openssl base64 | tr -d \\n) rm ed25519-priv.pem cat >> $GITHUB_STEP_SUMMARY << EOF ### Artifact Information :information_source: @@ -118,4 +136,4 @@ runs: uses: actions/upload-artifact@v6 with: name: PrismLauncher-${{ inputs.artifact-name }}-${{ inputs.version }}-${{ inputs.build-type }} - path: PrismLauncher.zip + path: PrismLauncher.dmg