|
5 | 5 | branches:
|
6 | 6 | - main
|
7 | 7 |
|
| 8 | +permissions: |
| 9 | + contents: write |
| 10 | + |
8 | 11 | jobs:
|
9 |
| - publish-tauri: |
10 |
| - permissions: |
11 |
| - contents: write |
| 12 | + build: |
12 | 13 | strategy:
|
13 |
| - fail-fast: false |
14 | 14 | matrix:
|
15 |
| - include: |
16 |
| - - platform: 'macos-latest' # for Arm based macs (M1 and above). |
17 |
| - args: '--target aarch64-apple-darwin' |
18 |
| - - platform: 'macos-latest' # for Intel based macs. |
19 |
| - args: '--target x86_64-apple-darwin' |
20 |
| - - platform: 'ubuntu-22.04' |
21 |
| - args: '' |
22 |
| - - platform: 'windows-latest' |
23 |
| - args: '' |
24 |
| - |
25 |
| - runs-on: ${{ matrix.platform }} |
| 15 | + os: [ 'macos-latest', 'ubuntu-22.04', 'windows-latest' ] |
| 16 | + runs-on: ${{ matrix.os }} |
26 | 17 | steps:
|
27 | 18 | - uses: actions/checkout@v4
|
28 | 19 |
|
29 |
| - - name: install dependencies (ubuntu only) |
30 |
| - if: matrix.platform == 'ubuntu-22.04' # This must match the platform value defined above. |
| 20 | + - name: Install dependencies (ubuntu only) |
| 21 | + if: matrix.os == 'ubuntu-22.04' # This must match the platform value defined above. |
31 | 22 | run: |
|
32 | 23 | sudo apt-get update
|
33 | 24 | sudo apt-get install -y libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev patchelf
|
34 | 25 |
|
35 |
| - - name: setup node |
| 26 | + - name: Install Node |
36 | 27 | uses: actions/setup-node@v4
|
37 | 28 | with:
|
38 | 29 | node-version: lts/*
|
39 |
| - cache: 'npm' # Set this to npm, yarn or pnpm. |
| 30 | + cache: 'npm' |
40 | 31 | cache-dependency-path: ./package.json
|
41 | 32 |
|
42 |
| - - name: install Rust stable |
43 |
| - uses: dtolnay/rust-toolchain@stable # Set this to dtolnay/rust-toolchain@nightly |
44 |
| - with: |
45 |
| - # Those targets are only used on macos runners so it's in an `if` to slightly speed up windows and linux builds. |
46 |
| - targets: ${{ matrix.platform == 'macos-latest' && 'aarch64-apple-darwin,x86_64-apple-darwin' || '' }} |
| 33 | + - name: Install Rust |
| 34 | + uses: dtolnay/rust-toolchain@stable |
47 | 35 |
|
48 |
| - - name: Rust cache |
| 36 | + - name: Rust Cache |
49 | 37 | uses: swatinem/rust-cache@v2
|
50 | 38 | with:
|
51 | 39 | workspaces: './src-tauri -> target'
|
52 | 40 |
|
53 |
| - - name: install frontend dependencies |
54 |
| - # If you don't have `beforeBuildCommand` configured you may want to build your frontend here too. |
55 |
| - run: npm install # change this to npm or pnpm depending on which one you use. |
| 41 | + - name: Install Frontend Dependencies |
| 42 | + run: npm install |
56 | 43 |
|
57 |
| - - uses: tauri-apps/tauri-action@v0.5.16 |
| 44 | + - name: Build Desktop |
| 45 | + uses: tauri-apps/tauri-action@v0.5.16 |
58 | 46 | env:
|
59 | 47 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
60 | 48 | with:
|
61 |
| - tagName: foxogram-${{github.run_id}} # the action automatically replaces \_\_VERSION\_\_ with the app version. |
| 49 | + tagName: foxogram-${{github.run_id}} |
62 | 50 | releaseName: 'Foxogram ${{github.run_id}}'
|
63 | 51 | prerelease: false
|
64 |
| - args: ${{ matrix.args }} |
0 commit comments