ci: merge clang-format and clang-tidy into single pipeline (#14798)

This commit is contained in:
Don Isaac
2024-10-24 15:26:05 -07:00
committed by GitHub
parent 9643a924e1
commit 0e4006eefd
2 changed files with 8 additions and 44 deletions

View File

@@ -1,41 +0,0 @@
name: clang-tidy
permissions:
contents: write
on:
workflow_call:
workflow_dispatch:
pull_request:
merge_group:
env:
BUN_VERSION: "1.1.27"
LLVM_VERSION: "18.1.8"
LLVM_VERSION_MAJOR: "18"
jobs:
clang-tidy:
name: clang-tidy
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Bun
uses: ./.github/actions/setup-bun
with:
bun-version: ${{ env.BUN_VERSION }}
- name: Install LLVM
run: |
curl -fsSL https://apt.llvm.org/llvm.sh | sudo bash -s -- ${{ env.LLVM_VERSION_MAJOR }} all
- name: Clang Tidy
env:
LLVM_VERSION: ${{ env.LLVM_VERSION }}
run: |
bun run clang-tidy:diff
- name: Commit
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: "`bun run clang-tidy`"

View File

@@ -1,4 +1,4 @@
name: clang-format
name: clang
permissions:
contents: write
@@ -15,8 +15,8 @@ env:
LLVM_VERSION_MAJOR: "18"
jobs:
clang-format:
name: clang-format
clang:
name: clang
runs-on: ubuntu-latest
steps:
- name: Checkout
@@ -35,6 +35,11 @@ jobs:
LLVM_VERSION: ${{ env.LLVM_VERSION }}
run: |
bun run clang-format
- name: Clang Tidy
env:
LLVM_VERSION: ${{ env.LLVM_VERSION }}
run: |
bun run clang-tidy:diff
- name: Commit
uses: stefanzweifel/git-auto-commit-action@v5
with: