Skip to content

feat: add function

feat: add function #1

Workflow file for this run

name: cpp-linter
permissions:
checks: write
pull-requests: write
repository-projects: write
on:
push:
paths:
- "src/**"
- "!**.md"
env:
BUILD_TYPE: Release
jobs:
cpp-linter:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: Setup Ninja
uses: ashutoshvarma/[email protected]
with:
version: '1.11.1'
- name: Configure CMake
run: cmake -G Ninja -S ${{github.workspace}} -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
- uses: cpp-linter/cpp-linter-action@v2
id: linter
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
version: '16'
style: file
database: ${{github.workspace}}/build
tidy-checks: -modernize-use-trailing-return-type,-readability-avoid-const-params-in-decls
file-annotations: false
step-summary: true
thread-comments: ${{ github.event_name == 'pull_request' }}
lines-changed-only: false
files-changed-only: true
- name: Failed if needed
if: steps.linter.outputs.checks-failed > 0
run: exit 1