-
Notifications
You must be signed in to change notification settings - Fork 70
56 lines (53 loc) · 1.58 KB
/
rust.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
name: Rust
on:
push:
branches:
- master
pull_request:
jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- name: Ubuntu GTK
os: ubuntu-latest
target: x86_64-unknown-linux-gnu
flags: '--no-default-features --features gtk3'
- name: Ubuntu XDG
os: ubuntu-latest
target: x86_64-unknown-linux-gnu
flags: '--no-default-features --features xdg-portal'
- name: Windows
os: windows-latest
target: x86_64-pc-windows-msvc
flags: ''
- name: Windows CC6
os: windows-latest
target: x86_64-pc-windows-msvc
flags: '--features common-controls-v6'
- name: macOS
os: macos-latest
target: x86_64-apple-darwin
flags: ''
- name: WASM32
os: ubuntu-latest
target: wasm32-unknown-unknown
flags: ''
name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- name: "[Ubuntu] install dependencies"
if: matrix.name == 'Ubuntu GTK'
run: sudo apt update && sudo apt install libgtk-3-dev
- name: "[WASM] rustup"
if: matrix.name == 'WASM32'
run: rustup target add wasm32-unknown-unknown
- uses: Swatinem/rust-cache@v2
- name: Build
run: cargo build --target ${{ matrix.target }} ${{ matrix.flags }}
- name: Test
# FIXME
if: matrix.name != 'WASM32'
run: cargo test --target ${{ matrix.target }} ${{ matrix.flags }}