Skip to content

chore(bindings): TypeScript 7 + nodenext resolution + Biome canon ado… #94

chore(bindings): TypeScript 7 + nodenext resolution + Biome canon ado…

chore(bindings): TypeScript 7 + nodenext resolution + Biome canon ado… #94

name: Static Analysis
on:
push:
branches: [ main, master ]
pull_request:
branches: [ main, master ]
permissions:
contents: read
concurrency:
group: static-analysis-${{ github.ref }}
cancel-in-progress: true
jobs:
clang-tidy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v7
with:
submodules: true
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y \
clang-tidy \
cmake \
pkg-config \
libspdlog-dev \
python3-yaml
- name: Check workflow contracts
run: |
tests/workflow-contracts.sh
tests/workflow-contracts-negative.sh
- name: Configure CMake
run: cmake -B build -DSRTLA_BUILD_TESTS=OFF -DSRTLA_ENABLE_CLANG_TIDY=OFF
- name: Run clang-tidy
run: |
cmake --build build --target lint
test:
runs-on: ubuntu-latest
env:
CCACHE_DIR: ${{ github.workspace }}/.ccache
CCACHE_MAXSIZE: 200M
steps:
- name: Checkout code
uses: actions/checkout@v7
with:
submodules: true
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y \
cmake \
pkg-config \
libspdlog-dev \
ccache
- name: Cache ccache
uses: actions/cache@v6
with:
path: ${{ env.CCACHE_DIR }}
key: ccache-${{ runner.os }}-amd64-gcc-test-${{ github.sha }}
restore-keys: |
ccache-${{ runner.os }}-amd64-gcc-test-
- name: Configure bounded ccache
run: ccache -M "$CCACHE_MAXSIZE"
- name: Configure CMake
run: |
cmake -B build -DSRTLA_BUILD_TESTS=ON \
-DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache
- name: Build
run: |
cmake --build build
- name: Run tests
run: |
cd build && ctest --output-on-failure
- name: Enforce ccache bound
if: ${{ always() }}
run: |
if command -v ccache >/dev/null 2>&1; then
ccache -c
fi