-
Notifications
You must be signed in to change notification settings - Fork 24
52 lines (47 loc) · 1.39 KB
/
style.yaml
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
name: C++ Lint CI
on:
push:
branches: [ main ]
pull_request:
env:
vcpkg_SHA: "2024.09.30"
jobs:
clang-format:
name: clang-format
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: clang-format
run: >
git ls-files -z -- '*.h' '*.cc' |
xargs -P 2 -n 50 -0 clang-format-14 -i
- name: check-diff
run: git diff --ignore-submodules=all --color --exit-code .
cmake-format:
name: cmake-format
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: install cmake-format
run: pip install cmakelang==0.6.13
- name: cmake-format
run: >
git ls-files -z -- '*.cmake' '**/CMakeLists.txt' CMakeLists.txt |
xargs -P 2 -n 1 -0 /home/runner/.local/bin/cmake-format -i
- name: check-diff
run: git diff --ignore-submodules=all --color --exit-code .
generated-files:
name: generated-files
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: install ninja
run: sudo apt install moreutils
- name: regenerate-build-examples
run: >
./ci/generate-build-examples.sh >ci/build-examples.yaml
- name: update-markdown-code-snippets
run: >
./ci/update-markdown-code-snippets.sh
- name: check-diff
run: git diff --ignore-submodules=all --color --exit-code .