Repository navigation
fix: align tauri dialog plugin versions #4
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 desktop builds | |
| on: | |
| push: | |
| tags: | |
| - "v*" | |
| workflow_dispatch: | |
| permissions: | |
| contents: write | |
| env: | |
| # Next.js must emit a static export so Tauri can bundle ../out | |
| NEXT_EXPORT: "1" | |
| jobs: | |
| build: | |
| name: ${{ matrix.platform }} | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - platform: macOS (Apple Silicon) | |
| os: macos-14 | |
| target: aarch64-apple-darwin | |
| bin-ext: "" | |
| - platform: macOS (Intel) | |
| os: macos-13 | |
| target: x86_64-apple-darwin | |
| bin-ext: "" | |
| - platform: Linux (x86_64) | |
| os: ubuntu-22.04 | |
| target: x86_64-unknown-linux-gnu | |
| bin-ext: "" | |
| - platform: Windows (x86_64) | |
| os: windows-latest | |
| target: x86_64-pc-windows-msvc | |
| bin-ext: ".exe" | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Install Linux system dependencies | |
| if: matrix.os == 'ubuntu-22.04' | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y \ | |
| libwebkit2gtk-4.1-dev \ | |
| libappindicator3-dev \ | |
| librsvg2-dev \ | |
| patchelf \ | |
| build-essential \ | |
| curl wget file \ | |
| libssl-dev \ | |
| libgtk-3-dev \ | |
| libxdo-dev \ | |
| libpango-1.0-0 \ | |
| libpangocairo-1.0-0 \ | |
| libgdk-pixbuf-2.0-0 \ | |
| libcairo2 \ | |
| libffi-dev | |
| - name: Install Rust toolchain | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| targets: ${{ matrix.target }} | |
| - name: Cache cargo registry and build | |
| uses: swatinem/rust-cache@v2 | |
| with: | |
| workspaces: frontend/src-tauri -> target | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v5 | |
| with: | |
| enable-cache: true | |
| - name: Install Python | |
| run: uv python install | |
| - name: Build backend sidecar | |
| run: | | |
| uv sync --frozen | |
| uv run pyinstaller markdown-reader-backend.spec | |
| - name: Stage sidecar with target triple | |
| shell: bash | |
| run: | | |
| mkdir -p frontend/src-tauri/binaries | |
| src="dist/markdown-reader-backend${{ matrix.bin-ext }}" | |
| dest="frontend/src-tauri/binaries/markdown-reader-backend-${{ matrix.target }}${{ matrix.bin-ext }}" | |
| cp "$src" "$dest" | |
| chmod +x "$dest" || true | |
| - name: Setup Node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: npm | |
| cache-dependency-path: frontend/package-lock.json | |
| - name: Install frontend dependencies | |
| working-directory: frontend | |
| run: npm ci | |
| - name: Build and release | |
| uses: tauri-apps/tauri-action@v0 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| projectPath: frontend | |
| tagName: ${{ github.ref_name }} | |
| releaseName: "Markdown Reader ${{ github.ref_name }}" | |
| releaseDraft: true | |
| prerelease: false | |
| args: --target ${{ matrix.target }} |