Skip to content

Commit a3b8ec2

Browse files
authored
Update main.yml
1 parent d5e919e commit a3b8ec2

File tree

1 file changed

+7
-10
lines changed

1 file changed

+7
-10
lines changed

.github/workflows/main.yml

+7-10
Original file line numberDiff line numberDiff line change
@@ -16,36 +16,33 @@ jobs:
1616
strategy:
1717
fail-fast: false
1818
matrix:
19-
toolchain: ['stable', 'nightly']
20-
include:
19+
toolchain: [stable, nightly]
20+
platform:
2121
- { target: aarch64-apple-darwin, os: macos-14 }
2222
- { target: x86_64-apple-darwin, os: macos-13 }
2323
- { target: x86_64-unknown-linux-gnu, os: ubuntu-latest }
2424
- { target: aarch64-unknown-linux-gnu, os: ubuntu-latest }
2525
- { target: x86_64-pc-windows-msvc, os: windows-latest }
26-
runs-on: ${{ matrix.os }}
26+
runs-on: ${{ matrix.platform.os }}
2727
env:
2828
HARFBUZZ_SYS_NO_PKG_CONFIG: true
2929
steps:
3030
- uses: actions/checkout@v4
3131
- uses: dtolnay/rust-toolchain@v1
3232
with:
3333
toolchain: ${{ matrix.toolchain }}
34-
target: ${{ matrix.target }}
34+
target: ${{ matrix.platform.target }}
3535
- name: Install packages
36-
if: ${{ matrix.os == 'ubuntu-latest' }}
36+
if: ${{ matrix.platform.os == 'ubuntu-latest' }}
3737
run: |
3838
sudo apt-get update
3939
sudo apt-get install -y libegl1-mesa-dev libgtk-3-dev libsdl2-dev cmake
40-
41-
- name: Install rustc target
42-
run: rustup target add aarch64-unknown-linux-gnu
4340
4441
- name: Build
45-
run: cargo build --target ${{ matrix.target }}
42+
run: cargo build --target ${{ matrix.platform.target }}
4643

4744
- name: Test
48-
if: ${{ matrix.target != 'aarch64-unknown-linux-gnu' }}
45+
if: ${{ matrix.platform.target != 'aarch64-unknown-linux-gnu' }}
4946
run: cargo test
5047

5148
build_result:

0 commit comments

Comments
 (0)