forked from pop-os/cosmic-comp
-
Notifications
You must be signed in to change notification settings - Fork 0
82 lines (78 loc) · 2.73 KB
/
ci.yml
File metadata and controls
82 lines (78 loc) · 2.73 KB
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:
branches: [master]
pull_request:
branches: [master]
jobs:
format:
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v5
- name: Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt
- name: Cargo cache
uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.toml') }}
- name: Format
run: cargo +stable fmt --all -- --check
check-features:
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v5
- name: Rust toolchain
uses: dtolnay/rust-toolchain@stable
- name: Cargo cache
uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.toml') }}
- name: System dependencies
run: sudo apt-get update; sudo apt-get install libudev-dev libgbm-dev libxkbcommon-dev libegl1-mesa-dev libwayland-dev libinput-dev libdbus-1-dev libsystemd-dev libseat-dev libdisplay-info-dev
- run: cargo +stable check --no-default-features
- run: cargo +stable check --features debug
- run: cargo +stable check --features profile-with-tracy
test:
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v5
- name: Rust toolchain
uses: dtolnay/rust-toolchain@stable
- name: Cargo cache
uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.toml') }}
- name: System dependencies
run: sudo apt-get update; sudo apt-get install libudev-dev libgbm-dev libxkbcommon-dev libegl1-mesa-dev libwayland-dev libinput-dev libdbus-1-dev libsystemd-dev libdisplay-info-dev libpixman-1-dev meson ninja-build
- name: Build cache
uses: actions/cache@v4
with:
path: target
key: ${{ runner.os }}-build-${{ hashFiles('**/Cargo.toml') }}
- name: Build and install Libseat
run: |
wget https://git.sr.ht/~kennylevinsen/seatd/archive/0.9.1.tar.gz -O libseat-source.tar.gz
tar xf libseat-source.tar.gz
cd seatd-0.9.1
meson setup -Dlibseat-builtin=enabled -Dserver=disabled -Dexamples=disabled -Dman-pages=disabled build .
ninja -C build
sudo meson install -C build
sudo ldconfig
- name: Test features
env:
RUST_BACKTRACE: full
run: cargo test --all-features