-
Notifications
You must be signed in to change notification settings - Fork 23
67 lines (65 loc) · 1.83 KB
/
build.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
57
58
59
60
61
62
63
64
65
66
67
name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
schedule:
- cron: "0 3 1 * *"
jobs:
test:
name: Test
runs-on: ${{ matrix.os }}
strategy:
matrix:
build: [x86_64, x86_64-beta, x86_64-nightly, i686, macos]
include:
- build: x86_64
os: ubuntu-latest
rust: stable
target: x86_64-unknown-linux-gnu
- build: x86_64-beta
os: ubuntu-latest
rust: beta
target: x86_64-unknown-linux-gnu
- build: x86_64-nightly
os: ubuntu-latest
rust: nightly
target: x86_64-unknown-linux-gnu
- build: i686
os: ubuntu-latest
rust: stable
target: i686-unknown-linux-gnu
- build: macos
os: macos-latest
rust: stable
target: x86_64-apple-darwin
- build: win32
os: windows-latest
rust: stable
target: i686-pc-windows-msvc
- build: win64
os: windows-latest
rust: stable
target: x86_64-pc-windows-msvc
steps:
- uses: actions/checkout@v2
- name: Install Rust (rustup)
run: rustup update ${{ matrix.rust }} --no-self-update && rustup default ${{ matrix.rust }}
shell: bash
- run: rustup target add ${{ matrix.target }}
- run: rustup component add clippy
- run: cargo fmt -- --check
if: matrix.build == 'x86_64'
name: Check formatting
- run: cargo clippy -- -D warnings
name: Run clippy
- run: cargo build
name: Build
- run: cargo test
name: Run tests
- run: |
cargo update -Z minimal-versions
cargo build
if: matrix.rust == 'nightly'
name: Check minimal versions