Add GitHub and Ko-fi usernames for funding #50
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: 'publish' | |
| on: | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| publish-tauri: | |
| permissions: | |
| contents: write | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| # --- LINUX x64 --- | |
| - platform: 'ubuntu-24.04' | |
| target: 'x86_64-unknown-linux-gnu' | |
| args: '' | |
| # --- LINUX ARM64 --- | |
| - platform: 'ubuntu-24.04' | |
| target: 'aarch64-unknown-linux-gnu' | |
| args: '' | |
| # --- WINDOWS x64 --- | |
| - platform: 'windows-latest' | |
| target: 'x86_64-pc-windows-msvc' | |
| args: '' | |
| # --- WINDOWS ARM64 --- | |
| - platform: 'windows-latest' | |
| target: 'aarch64-pc-windows-msvc' | |
| args: '' | |
| # # --- MACOS x64 --- | |
| - platform: 'macos-latest' | |
| target: 'x86_64-apple-darwin' | |
| args: '' | |
| # # --- MACOS ARM64 --- | |
| - platform: 'macos-latest' | |
| target: 'aarch64-apple-darwin' | |
| args: '--target aarch64-apple-darwin' | |
| runs-on: ${{ matrix.platform }} | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v6 | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v5 | |
| with: | |
| version: 10 | |
| - name: Setup node | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: lts/* | |
| cache: 'pnpm' | |
| - name: Install Rust stable | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| targets: ${{ matrix.target }} | |
| - name: Rust cache | |
| uses: swatinem/rust-cache@v2 | |
| with: | |
| # On ajoute la target dans la clé pour ne pas mélanger | |
| # le cache Windows x64 et Windows ARM64 | |
| key: ${{ matrix.target }} | |
| workspaces: 'src-tauri -> target' | |
| - name: Install dependencies (Ubuntu x64) | |
| if: matrix.platform == 'ubuntu-24.04' && matrix.target == 'x86_64-unknown-linux-gnu' | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev patchelf | |
| - name: Install dependencies (Ubuntu ARM64) | |
| if: matrix.platform == 'ubuntu-24.04' && matrix.target == 'aarch64-unknown-linux-gnu' | |
| run: | | |
| sudo dpkg --add-architecture arm64 | |
| sudo apt-get update | |
| sudo apt-get install -y \ | |
| gcc-aarch64-linux-gnu \ | |
| g++-aarch64-linux-gnu \ | |
| libwebkit2gtk-4.1-dev:arm64 \ | |
| libappindicator3-dev:arm64 \ | |
| librsvg2-dev:arm64 \ | |
| patchelf | |
| - name: Configure Ubuntu ARM64 cross-compilation | |
| if: matrix.platform == 'ubuntu-24.04' && matrix.target == 'aarch64-unknown-linux-gnu' | |
| run: | | |
| echo "PKG_CONFIG_ALLOW_CROSS=1" >> "$GITHUB_ENV" | |
| echo "PKG_CONFIG_PATH=/usr/lib/aarch64-linux-gnu/pkgconfig" >> "$GITHUB_ENV" | |
| echo "PKG_CONFIG_LIBDIR=/usr/lib/aarch64-linux-gnu/pkgconfig:/usr/share/pkgconfig" >> "$GITHUB_ENV" | |
| echo "CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=aarch64-linux-gnu-gcc" >> "$GITHUB_ENV" | |
| echo "CC_aarch64_unknown_linux_gnu=aarch64-linux-gnu-gcc" >> "$GITHUB_ENV" | |
| echo "CXX_aarch64_unknown_linux_gnu=aarch64-linux-gnu-g++" >> "$GITHUB_ENV" | |
| - name: Install frontend dependencies | |
| run: pnpm install | |
| - name: Install sccache | |
| uses: mozilla/sccache-action@v0.0.9 | |
| - name: Build and Release Tauri App | |
| uses: tauri-apps/tauri-action@v0 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }} | |
| TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }} | |
| SCCACHE_GHA_ENABLED: "true" | |
| RUSTC_WRAPPER: "sccache" | |
| with: | |
| tagName: v__VERSION__ | |
| releaseName: 'Voltius v__VERSION__' | |
| releaseBody: 'See the assets to download this version.' | |
| releaseDraft: false | |
| prerelease: false | |
| # CORRECTION: Il fallait passer l'argument ici pour cibler l'ARM64 ! | |
| args: ${{ matrix.args }} | |
| # Upload le binaire brut (.exe portable) en plus des installeurs | |
| uploadPlainBinary: true | |
| updaterJsonPreferNsis: true |