Skip to content

Commit 90ae51d

Browse files
committed
Add .clang-format CI check
1 parent 666dba1 commit 90ae51d

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

.github/workflows/formatting.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Copyright 2024 The Khronos Group Inc.
2+
# Copyright 2024 RasterGrid Kft.
3+
# SPDX-License-Identifier: Apache-2.0
4+
name: Formatting
5+
6+
on:
7+
workflow_call:
8+
9+
permissions:
10+
contents: read
11+
12+
jobs:
13+
clang-format:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v4
17+
- name: Run clang-format
18+
uses: jidicula/[email protected]
19+
with:
20+
clang-format-version: '17'

.github/workflows/windows.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,11 @@ on:
2525
workflow_dispatch:
2626

2727
jobs:
28+
formatting:
29+
uses: ./.github/workflows/formatting.yml
2830
windows:
31+
# Shortcircuit and don't burn CI time when formatting will reject
32+
needs: formatting
2933
strategy:
3034
matrix:
3135
os: [ windows-latest ]

0 commit comments

Comments
 (0)