SWDEV-470698 - fix formatting, add format check workflow (#657)
This commit is contained in:
کامیت شده توسط
GitHub
والد
5840940caa
کامیت
f7338717ae
@@ -0,0 +1,27 @@
|
||||
name: Clang format check
|
||||
on:
|
||||
pull_request:
|
||||
types: [synchronize, opened]
|
||||
paths:
|
||||
- 'projects/hip/**'
|
||||
- 'projects/clr/**'
|
||||
- 'projects/hipother/**'
|
||||
- 'projects/hip-tests/**'
|
||||
|
||||
jobs:
|
||||
format:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Install clang-format
|
||||
run: |
|
||||
sudo apt update && sudo apt install -y clang-format
|
||||
|
||||
- name: Run clang-format-check
|
||||
id: clang-format
|
||||
run: |
|
||||
chmod +x .github/hooks/clang-format-check.sh
|
||||
./.github/hooks/clang-format-check.sh --range "${{ github.event.pull_request.base.sha }}..${{ github.event.pull_request.head.sha }}"
|
||||
مرجع در شماره جدید
Block a user