Skip to content

Add pass to print pr.sources to a SARIF file #1135

Add pass to print pr.sources to a SARIF file

Add pass to print pr.sources to a SARIF file #1135

Workflow file for this run

#
# Copyright (c) 2023, Trail of Bits, Inc.
# All rights reserved.
#
# This source code is licensed in accordance with the terms specified in
# the LICENSE file found in the root directory of this source tree.
#
name: Linters
on:
pull_request:
paths-ignore: "docs/**"
jobs:
cpp-linter:
strategy:
matrix:
llvm-version: [19]
image-version: [22.04]
runs-on: ubuntu-${{ matrix.image-version }}
container:
image:
ghcr.io/trailofbits/vast-ubuntu-${{ matrix.image-version }}-llvm-${{ matrix.llvm-version }}-dev:latest
permissions:
actions: write
issues: write
pull-requests: write
packages: read
env:
CMAKE_PREFIX_PATH: "/usr/lib/llvm-${{ matrix.llvm-version }}/lib/cmake/mlir/;/usr/lib/llvm-${{ matrix.llvm-version }}/lib/cmake/clang/"
steps:
- name: Remove safety checks for pygit
run: git config --global --add safe.directory '*'
- name: Clone the vast repository
uses: actions/checkout@v4
with:
submodules: true
fetch-depth: 1
- name: Export compile commands
run: cmake --preset ci
- name: Install dependencies
run: |
pip3 install clang-tools cpp-linter
clang-tools -i ${{ matrix.llvm-version }}
- name: Run C++ Linters
uses: xlauko/cpp-linter-action@latest
id: linter
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
version: ${{ matrix.llvm-version }}
style: file
database: ./builds/ci/
lines-changed-only: true
thread-comments: true
step-summary: true
ignore: 'test'
tidy-checks: ''
- name: Report result
if: steps.linter.outputs.checks-failed > 0
run:
echo "Some files failed the linting checks!"
exit 1