-
Notifications
You must be signed in to change notification settings - Fork 0
74 lines (57 loc) · 1.66 KB
/
Copy pathci.yml
File metadata and controls
74 lines (57 loc) · 1.66 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
name: CI
on:
push:
branches: [main]
pull_request:
jobs:
check:
runs-on: ubuntu-latest
container: archlinux:latest
steps:
- uses: actions/checkout@v4
- name: System dependencies
run: |
pacman -Syu --noconfirm --needed \
base-devel \
gtk4 libadwaita glib2 \
pkgconf
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt, clippy
- uses: Swatinem/rust-cache@v2
- name: Format
run: cargo fmt --check
- name: Clippy
run: cargo clippy --all-targets -- -D warnings
- name: Test
run: cargo test
- name: i18n catalog parity
run: |
python3 tools/gen-translations.py po/es.po /tmp/es-regenerated.rs
diff -u src/util/translations/es.rs /tmp/es-regenerated.rs
- name: Build release
run: cargo build --release
coverage:
runs-on: ubuntu-latest
container: archlinux:latest
steps:
- uses: actions/checkout@v4
- name: System dependencies
run: |
pacman -Syu --noconfirm --needed \
base-devel \
gtk4 libadwaita glib2 \
pkgconf
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt, clippy, llvm-tools-preview
- uses: taiki-e/install-action@cargo-llvm-cov
- uses: Swatinem/rust-cache@v2
- name: Generate coverage
run: cargo llvm-cov --lcov --output-path lcov.info
- name: Upload coverage artifact
uses: actions/upload-artifact@v4
with:
name: lcov-info
path: lcov.info
if-no-files-found: error