Bump version to 2.0.0 #7
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Release | |
| on: | |
| push: | |
| tags: | |
| - 'v*' | |
| jobs: | |
| build-windows: | |
| runs-on: windows-latest | |
| outputs: | |
| version: ${{ steps.version.outputs.VERSION }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Read version | |
| id: version | |
| shell: pwsh | |
| run: | | |
| $v = (Select-String -Path "matchy/Cargo.toml" -Pattern '^version\s*=\s*"([^"]+)"' | Select-Object -First 1).Matches.Groups[1].Value | |
| echo "VERSION=$v" >> $env:GITHUB_OUTPUT | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| - name: Setup Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Remove local-only cargo config | |
| shell: pwsh | |
| run: Remove-Item -Path matchy/.cargo/config.toml -Force -ErrorAction SilentlyContinue | |
| - name: Install frontend dependencies | |
| working-directory: matchy/crates/matchy-app/frontend | |
| run: npm ci | |
| - name: Build Tauri app | |
| shell: pwsh | |
| working-directory: matchy/crates/matchy-app | |
| run: .\frontend\node_modules\.bin\tauri.cmd build | |
| - name: Build CLI | |
| working-directory: matchy | |
| run: cargo build --release -p matchy-cli | |
| - name: Create portable zip | |
| shell: pwsh | |
| run: | | |
| $Version = "${{ steps.version.outputs.VERSION }}" | |
| New-Item -ItemType Directory -Force -Path dist | Out-Null | |
| Compress-Archive -Path "matchy/target/release/matchy-app.exe" ` | |
| -DestinationPath "dist/MatchY-${Version}-x64-windows-portable.zip" -Force | |
| - name: Upload NSIS installer | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: windows-nsis | |
| path: matchy/target/release/bundle/nsis/*.exe | |
| - name: Upload MSI | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: windows-msi | |
| path: matchy/target/release/bundle/msi/*.msi | |
| - name: Upload portable zip | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: windows-portable | |
| path: dist/*.zip | |
| - name: Upload CLI | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: windows-cli | |
| path: matchy/target/release/matchy.exe | |
| build-linux: | |
| runs-on: ubuntu-22.04 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install system dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y \ | |
| libwebkit2gtk-4.1-dev \ | |
| libappindicator3-dev \ | |
| librsvg2-dev \ | |
| patchelf \ | |
| musl-tools | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| - name: Setup Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| targets: x86_64-unknown-linux-musl | |
| - name: Install frontend dependencies | |
| working-directory: matchy/crates/matchy-app/frontend | |
| run: npm ci | |
| - name: Build Tauri app (AppImage) | |
| working-directory: matchy/crates/matchy-app | |
| run: ./frontend/node_modules/.bin/tauri build --bundles appimage | |
| - name: Build CLI (static musl) | |
| working-directory: matchy | |
| run: cargo build --release -p matchy-cli --target x86_64-unknown-linux-musl | |
| - name: Upload AppImage | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: linux-appimage | |
| path: matchy/target/release/bundle/appimage/*.AppImage | |
| - name: Upload CLI | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: linux-cli | |
| path: matchy/target/x86_64-unknown-linux-musl/release/matchy | |
| build-macos-arm: | |
| runs-on: macos-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| - name: Setup Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Install frontend dependencies | |
| working-directory: matchy/crates/matchy-app/frontend | |
| run: npm ci | |
| - name: Build Tauri app (DMG, unsigned) | |
| working-directory: matchy/crates/matchy-app | |
| run: ./frontend/node_modules/.bin/tauri build --bundles dmg | |
| env: | |
| APPLE_SIGNING_IDENTITY: '-' | |
| - name: Build CLI | |
| working-directory: matchy | |
| run: cargo build --release -p matchy-cli | |
| - name: Upload DMG | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: macos-arm-dmg | |
| path: matchy/target/release/bundle/dmg/*.dmg | |
| - name: Upload CLI | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: macos-arm-cli | |
| path: matchy/target/release/matchy | |
| release: | |
| needs: [build-windows, build-linux, build-macos-arm] | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Read version | |
| id: version | |
| run: | | |
| VERSION=$(grep '^version\s*=' matchy/Cargo.toml | head -1 | sed 's/.*"\(.*\)".*/\1/') | |
| echo "VERSION=$VERSION" >> $GITHUB_OUTPUT | |
| - name: Download all artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| path: artifacts | |
| - name: Rename and stage release assets | |
| run: | | |
| VERSION="${{ steps.version.outputs.VERSION }}" | |
| mkdir -p release-assets | |
| find artifacts/windows-nsis -name "*.exe" -exec cp {} "release-assets/MatchY-${VERSION}-x64-windows-setup.exe" \; | |
| find artifacts/windows-msi -name "*.msi" -exec cp {} "release-assets/MatchY-${VERSION}-x64-windows.msi" \; | |
| find artifacts/windows-portable -name "*.zip" -exec cp {} "release-assets/MatchY-${VERSION}-x64-windows-portable.zip" \; | |
| find artifacts/windows-cli -name "matchy.exe" -exec cp {} "release-assets/matchy-${VERSION}-x86_64-windows.exe" \; | |
| find artifacts/linux-appimage -name "*.AppImage" -exec cp {} "release-assets/MatchY-${VERSION}-x86_64-linux.AppImage" \; | |
| find artifacts/linux-cli -name "matchy" -exec cp {} "release-assets/matchy-${VERSION}-x86_64-linux-musl" \; | |
| find artifacts/macos-arm-dmg -name "*.dmg" -exec cp {} "release-assets/MatchY-${VERSION}-aarch64-macos.dmg" \; | |
| find artifacts/macos-arm-cli -name "matchy" -exec cp {} "release-assets/matchy-${VERSION}-aarch64-macos" \; | |
| chmod +x release-assets/matchy-${VERSION}-x86_64-linux-musl \ | |
| release-assets/matchy-${VERSION}-aarch64-macos | |
| - name: Create GitHub Release | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| body_path: RELEASE_NOTES.md | |
| generate_release_notes: true | |
| files: release-assets/* |