File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -20,11 +20,32 @@ jobs:
2020 - name : Checkout repository
2121 uses : actions/checkout@v4
2222
23+ # ------------------------
24+ # Cache APT packages
25+ # ------------------------
26+ - name : Cache APT packages
27+ uses : actions/cache@v4
28+ with :
29+ path : /var/cache/apt
30+ key : apt-cache-${{ runner.os }}-${{ hashFiles('**/CMakeLists.txt') }}
31+ restore-keys : |
32+ apt-cache-${{ runner.os }}-
33+
2334 - name : Install dependencies (clang-tidy + HDF5 + OpenMP)
2435 run : |
2536 sudo apt-get update
26- sudo apt-get install -y clang-tidy libhdf5-dev
27- sudo apt-get install -y libomp-dev
37+ sudo apt-get install -y clang-tidy libhdf5-dev libomp-dev
38+
39+ # ------------------------
40+ # Cache CMake build directory
41+ # ------------------------
42+ - name : Cache CMake build
43+ uses : actions/cache@v4
44+ with :
45+ path : build
46+ key : cmake-${{ runner.os }}-${{ hashFiles('**/*.cpp', '**/*.h', '**/CMakeLists.txt') }}
47+ restore-keys : |
48+ cmake-${{ runner.os }}-
2849
2950 - name : Configure project (CMake)
3051 run : |
3657 run : |
3758 cmake --build build -- -j$(nproc)
3859
39- - name : Run clang-tidy using compile_commands.json
60+ - name : Run clang-tidy
4061 run : |
41- find src -name "*.cpp" | xargs -I{} clang-tidy {} -p build
62+ find src -name "*.cpp" | xargs -I{} clang-tidy {} -p build
You can’t perform that action at this time.
0 commit comments