v7.0.1
This commit is contained in:
+12
-92
@@ -90,89 +90,8 @@ jobs:
|
|||||||
path: dist/SpotiFLAC.exe
|
path: dist/SpotiFLAC.exe
|
||||||
retention-days: 7
|
retention-days: 7
|
||||||
|
|
||||||
build-macos-intel:
|
build-macos:
|
||||||
name: Build macOS Intel
|
name: Build macOS
|
||||||
runs-on: macos-15-intel
|
|
||||||
steps:
|
|
||||||
- name: Checkout code
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Get version from tag
|
|
||||||
id: version
|
|
||||||
run: |
|
|
||||||
if [[ "${{ github.ref }}" == refs/tags/* ]]; then
|
|
||||||
VERSION=${GITHUB_REF#refs/tags/}
|
|
||||||
else
|
|
||||||
VERSION="dev"
|
|
||||||
fi
|
|
||||||
echo "version=$VERSION" >> $GITHUB_OUTPUT
|
|
||||||
|
|
||||||
- name: Setup Go
|
|
||||||
uses: actions/setup-go@v5
|
|
||||||
with:
|
|
||||||
go-version: ${{ env.GO_VERSION }}
|
|
||||||
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: ${{ env.NODE_VERSION }}
|
|
||||||
|
|
||||||
- name: Install pnpm
|
|
||||||
uses: pnpm/action-setup@v4
|
|
||||||
with:
|
|
||||||
version: 9
|
|
||||||
|
|
||||||
- name: Get pnpm store directory
|
|
||||||
run: |
|
|
||||||
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
|
|
||||||
|
|
||||||
- name: Setup pnpm cache
|
|
||||||
continue-on-error: true
|
|
||||||
uses: actions/cache@v4
|
|
||||||
with:
|
|
||||||
path: ${{ env.STORE_PATH }}
|
|
||||||
key: ${{ runner.os }}-intel-pnpm-store-${{ hashFiles('frontend/pnpm-lock.yaml') }}
|
|
||||||
restore-keys: |
|
|
||||||
${{ runner.os }}-intel-pnpm-store-
|
|
||||||
|
|
||||||
- name: Install Wails CLI
|
|
||||||
run: go install github.com/wailsapp/wails/v2/cmd/wails@latest
|
|
||||||
|
|
||||||
- name: Install frontend dependencies
|
|
||||||
working-directory: frontend
|
|
||||||
run: |
|
|
||||||
pnpm install
|
|
||||||
pnpm run generate-icon
|
|
||||||
|
|
||||||
- name: Build application
|
|
||||||
run: wails build -platform darwin/amd64
|
|
||||||
|
|
||||||
- name: Create DMG
|
|
||||||
run: |
|
|
||||||
mkdir -p dist
|
|
||||||
brew install create-dmg || true
|
|
||||||
|
|
||||||
create-dmg \
|
|
||||||
--volname "SpotiFLAC" \
|
|
||||||
--window-pos 200 120 \
|
|
||||||
--window-size 600 400 \
|
|
||||||
--icon-size 100 \
|
|
||||||
--icon "SpotiFLAC.app" 175 120 \
|
|
||||||
--hide-extension "SpotiFLAC.app" \
|
|
||||||
--app-drop-link 425 120 \
|
|
||||||
"dist/SpotiFLAC-Intel.dmg" \
|
|
||||||
"build/bin/SpotiFLAC.app" || \
|
|
||||||
hdiutil create -volname SpotiFLAC -srcfolder build/bin/SpotiFLAC.app -ov -format UDZO dist/SpotiFLAC-Intel.dmg
|
|
||||||
|
|
||||||
- name: Upload artifacts
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: macos-intel
|
|
||||||
path: dist/SpotiFLAC-Intel.dmg
|
|
||||||
retention-days: 7
|
|
||||||
|
|
||||||
build-macos-arm:
|
|
||||||
name: Build macOS Apple Silicon
|
|
||||||
runs-on: macos-latest
|
runs-on: macos-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
@@ -212,9 +131,9 @@ jobs:
|
|||||||
uses: actions/cache@v4
|
uses: actions/cache@v4
|
||||||
with:
|
with:
|
||||||
path: ${{ env.STORE_PATH }}
|
path: ${{ env.STORE_PATH }}
|
||||||
key: ${{ runner.os }}-arm-pnpm-store-${{ hashFiles('frontend/pnpm-lock.yaml') }}
|
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('frontend/pnpm-lock.yaml') }}
|
||||||
restore-keys: |
|
restore-keys: |
|
||||||
${{ runner.os }}-arm-pnpm-store-
|
${{ runner.os }}-pnpm-store-
|
||||||
|
|
||||||
- name: Install Wails CLI
|
- name: Install Wails CLI
|
||||||
run: go install github.com/wailsapp/wails/v2/cmd/wails@latest
|
run: go install github.com/wailsapp/wails/v2/cmd/wails@latest
|
||||||
@@ -226,13 +145,15 @@ jobs:
|
|||||||
pnpm run generate-icon
|
pnpm run generate-icon
|
||||||
|
|
||||||
- name: Build application
|
- name: Build application
|
||||||
run: wails build -platform darwin/arm64
|
run: wails build -platform darwin/universal
|
||||||
|
|
||||||
- name: Create DMG
|
- name: Create DMG
|
||||||
run: |
|
run: |
|
||||||
mkdir -p dist
|
mkdir -p dist
|
||||||
|
# Install create-dmg if not available
|
||||||
brew install create-dmg || true
|
brew install create-dmg || true
|
||||||
|
|
||||||
|
# Create DMG
|
||||||
create-dmg \
|
create-dmg \
|
||||||
--volname "SpotiFLAC" \
|
--volname "SpotiFLAC" \
|
||||||
--window-pos 200 120 \
|
--window-pos 200 120 \
|
||||||
@@ -243,12 +164,13 @@ jobs:
|
|||||||
--app-drop-link 425 120 \
|
--app-drop-link 425 120 \
|
||||||
"dist/SpotiFLAC.dmg" \
|
"dist/SpotiFLAC.dmg" \
|
||||||
"build/bin/SpotiFLAC.app" || \
|
"build/bin/SpotiFLAC.app" || \
|
||||||
|
# Fallback to hdiutil if create-dmg fails
|
||||||
hdiutil create -volname SpotiFLAC -srcfolder build/bin/SpotiFLAC.app -ov -format UDZO dist/SpotiFLAC.dmg
|
hdiutil create -volname SpotiFLAC -srcfolder build/bin/SpotiFLAC.app -ov -format UDZO dist/SpotiFLAC.dmg
|
||||||
|
|
||||||
- name: Upload artifacts
|
- name: Upload artifacts
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: macos-arm
|
name: macos-portable
|
||||||
path: dist/SpotiFLAC.dmg
|
path: dist/SpotiFLAC.dmg
|
||||||
retention-days: 7
|
retention-days: 7
|
||||||
|
|
||||||
@@ -398,7 +320,7 @@ jobs:
|
|||||||
|
|
||||||
create-release:
|
create-release:
|
||||||
name: Create Release
|
name: Create Release
|
||||||
needs: [build-windows, build-macos-intel, build-macos-arm, build-linux]
|
needs: [build-windows, build-macos, build-linux]
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: startsWith(github.ref, 'refs/tags/v')
|
if: startsWith(github.ref, 'refs/tags/v')
|
||||||
permissions:
|
permissions:
|
||||||
@@ -433,8 +355,7 @@ jobs:
|
|||||||
## Downloads
|
## Downloads
|
||||||
|
|
||||||
- `SpotiFLAC.exe` - Windows
|
- `SpotiFLAC.exe` - Windows
|
||||||
- `SpotiFLAC-Intel.dmg` - macOS Intel
|
- `SpotiFLAC.dmg` - macOS
|
||||||
- `SpotiFLAC.dmg` - macOS Apple Silicon
|
|
||||||
- `SpotiFLAC.AppImage` - Linux
|
- `SpotiFLAC.AppImage` - Linux
|
||||||
|
|
||||||
<details>
|
<details>
|
||||||
@@ -466,8 +387,7 @@ jobs:
|
|||||||
</details>
|
</details>
|
||||||
files: |
|
files: |
|
||||||
artifacts/windows-portable/*.exe
|
artifacts/windows-portable/*.exe
|
||||||
artifacts/macos-intel/*.dmg
|
artifacts/macos-portable/*.dmg
|
||||||
artifacts/macos-arm/*.dmg
|
|
||||||
artifacts/linux-portable/*.AppImage
|
artifacts/linux-portable/*.AppImage
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|||||||
Reference in New Issue
Block a user