-
Notifications
You must be signed in to change notification settings - Fork 52
32 lines (27 loc) · 1.02 KB
/
format-check.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
name: Format check
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
merge_group:
jobs:
build:
# The CMake configure and build commands are platform agnostic and should work equally
# well on Windows or Mac. You can convert this to a matrix build if you need
# cross-platform coverage.
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Install dependencies
run: |
# The following line currently seems to be necessary to work around a bug in the installation.
sudo apt remove python3-lldb-*
wget https://apt.llvm.org/llvm.sh
sudo chmod +x llvm.sh
sed 's/apt-key del/echo/' llvm.sh -iy
sudo ./llvm.sh 16
sudo apt install -y clang-format-16
- name: Run the format checker
run: ${{github.workspace}}/misc/format-check.sh