-
Notifications
You must be signed in to change notification settings - Fork 5
29 lines (24 loc) · 880 Bytes
/
codeformat.yml
File metadata and controls
29 lines (24 loc) · 880 Bytes
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
name: Format (clang-format)
on:
push:
branches:
- 'master'
jobs:
clang-format:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}
- name: Set up clang-format
run: |
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
sudo add-apt-repository "deb http://apt.llvm.org/noble/ llvm-toolchain-noble-19 main"
sudo apt install clang-format-19
- name: Run clang-format
run: |
which clang-format-19
clang-format-19 -i Src/Source/*.cpp Src/Headers/*.h
- uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: Apply clang-format changes