-
Notifications
You must be signed in to change notification settings - Fork 36
82 lines (75 loc) · 2.92 KB
/
ci.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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
name: Continuous Integration
on:
push:
pull_request:
schedule:
- cron: "0 0 1,15 * *"
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macOS-latest]
rust: [stable, beta, nightly]
# "verbose" just means debug mode here, it's effectively a no-op flag
release: [verbose, release]
include:
- os: windows-latest
toolchain: -gnu
steps:
- uses: actions/checkout@v1
# windows deps
- name: (Windows) Install Gtk build environment
if: matrix.os == 'windows-latest'
uses: msys2/setup-msys2@v2
with:
path-type: inherit
install: >
mingw-w64-x86_64-gtk3
mingw-w64-x86_64-toolchain
# lunix deps
- name: (Lunix) Install Gtk build environment
if: matrix.os == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev
# mac deps
- name: (macOS) Install Gtk build environment
if: matrix.os == 'macOS-latest'
run: |
brew install gtk+3
# cargo away
- uses: hecrj/setup-rust-action@v1
with:
rust-version: ${{ matrix.rust }}${{ matrix.toolchain }}
- name: (Cowindows) Build tree
if: matrix.os != 'windows-latest'
run: cargo build --all-features --verbose --verbose --${{ matrix.release }}
- name: (Windows) Build tree
if: matrix.os == 'windows-latest'
shell: msys2 {0}
run: cargo build --all-features --verbose --verbose --${{ matrix.release }}
- name: Run tests in macros
run: cd macros; cargo test --all-features --verbose --verbose --${{ matrix.release }}
- name: (Cowindows) Run tests in lib
if: matrix.os != 'windows-latest'
run: cd vgtk; cargo test --all-features --verbose --verbose --${{ matrix.release }}
- name: (Windows) Run tests in lib
if: matrix.os == 'windows-latest'
shell: msys2 {0}
run: cd vgtk; cargo test --all-features --verbose --verbose --${{ matrix.release }}
clippy:
runs-on: ubuntu-latest
steps:
- name: Install Gtk build environment
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev
- uses: hecrj/setup-rust-action@v1
with:
rust-version: stable
components: clippy
- uses: actions/checkout@v1
- name: Clippy
run: cargo clippy -- -D warnings