forked from BigfootDev/flatbuffers
Create cpp-linter.yml (#7208)
* Create cpp-linter.yml * Update cpp-linter.yml * Update cpp-linter.yml * Update bfbs_gen_lua.cpp make some ill-formed edits to see if the linter flags them. * Update cpp-linter.yml Configured tidy checks * Update cpp-linter.yml Build project before linting to get compile_commands.json * Update cpp-linter.yml * Update cpp-linter.yml * Update cpp-linter.yml * Update cpp-linter.yml * Update cpp-linter.yml * lines only
This commit is contained in:
35
.github/workflows/cpp-linter.yml
vendored
Normal file
35
.github/workflows/cpp-linter.yml
vendored
Normal file
@@ -0,0 +1,35 @@
|
||||
name: cpp-linter
|
||||
permissions: read-all
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
paths-ignore: "tests/**"
|
||||
|
||||
jobs:
|
||||
cpp-linter:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: shenxianpeng/cpp-linter-action@master
|
||||
id: linter
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
version: 12
|
||||
style: file
|
||||
lines-changed-only: true
|
||||
tidy-checks: >-
|
||||
bugprone-*,
|
||||
performance-*,
|
||||
readability-*,
|
||||
portability-*,
|
||||
modernize-*,
|
||||
clang-analyzer-*,
|
||||
cppcoreguidelines-*,
|
||||
-modernize-use-trailing-return-type
|
||||
|
||||
- name: Check Result
|
||||
if: steps.linter.outputs.checks-failed > 0
|
||||
run: exit 1
|
||||
Reference in New Issue
Block a user