forked from gunrock/gunrock
-
Notifications
You must be signed in to change notification settings - Fork 0
34 lines (29 loc) · 904 Bytes
/
clang-format.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
32
33
34
name: Formatting
# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events but only for the main branch
push:
branches: [ main, develop ]
jobs:
formatting-check:
name: Format
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.ref }}
- name: Install clang-format
run: |
pip install clang-format \
&& clang-format --version
shell: bash
- name: Format files
run: ${{github.workspace}}/scripts/format.sh ${{github.workspace}} y
shell: bash
- name: Commit changes
uses: EndBug/add-and-commit@v9
with:
committer_name: GitHub Actions
committer_email: 41898282+github-actions[bot]@users.noreply.github.com
message: ':octocat: Applied clang-format.'
add: '*.cpp *.cu *.cuh *.hxx'