Skip to content

Clangtidy ci

Clangtidy ci #11

Workflow file for this run

name: Clang-tidy
on:
push:
branches:
-master
pull_request:
branches:
- main
- master
- development
types:
- opened
- reopened
- synchronize
- ready_for_review
concurrency:
group: ${{ github.event_name }}-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.event_name == 'pull_request'}}
jobs:
clang-tidy:
runs-on: [ubuntu-22.04]
container:
image: dealii/dealii:v9.6.0-jammy
options: --user root
steps:
- name: Checkout repo
uses: actions/checkout@v4
with:
fetch-depth: 30
- name: Cache llvm-16.0.0 installation
uses: actions/cache@v3
with:
path: /usr/lib/llvm-16
key: ${{ runner.os }}-llvm-16
restore-keys: |
${{ runner.os }}-llvm
- name: Install llvm-16.0.0
if: steps.cache.outputs.cache-hit != 'true'
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
./llvm.sh 16
- name: Set up path for llvm-16.0.0
run: |
echo "/usr/lib/llvm-16/bin" >> "$GITHUB_PATH"
echo "Current PATH: $PATH"
which clang
which clang++
which clang-tidy
- name: Run clang-tidy
run: |
./utilities/clang_tidy.sh .