From d9b83f7787dbfb4ecdbf49a9b621a7a3c1dff85c Mon Sep 17 00:00:00 2001 From: thomaslepoix Date: Wed, 9 Nov 2022 20:00:33 +0100 Subject: [PATCH] CI : add CodeQL workflow --- .github/workflows/test_codeql.yml | 40 ++++++++++++++++++++++++++++++ src/domain/geometrics/relation.cpp | 1 - 2 files changed, 40 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/test_codeql.yml diff --git a/.github/workflows/test_codeql.yml b/.github/workflows/test_codeql.yml new file mode 100644 index 0000000..175f1f0 --- /dev/null +++ b/.github/workflows/test_codeql.yml @@ -0,0 +1,40 @@ +name: Test CodeQL + +on: + workflow_dispatch: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + +jobs: + run: + runs-on: ubuntu-latest + + permissions: + actions: read + contents: read + security-events: write + + strategy: + fail-fast: false + matrix: + language: [ 'cpp' ] + + steps: + - name: Checkout + uses: actions/checkout@v3 + + - name: Init + uses: github/codeql-action/init@v2 + with: + languages: ${{ matrix.language }} + queries: security-extended,security-and-quality + + - name: Autobuild + uses: github/codeql-action/autobuild@v2 + + - name: Analyze + uses: github/codeql-action/analyze@v2 + with: + category: "/language:${{matrix.language}}" diff --git a/src/domain/geometrics/relation.cpp b/src/domain/geometrics/relation.cpp index b76d285..b24ee46 100644 --- a/src/domain/geometrics/relation.cpp +++ b/src/domain/geometrics/relation.cpp @@ -16,7 +16,6 @@ PolygonPoint cast(PolygonSegment const a) { case PolygonSegment::IN: return PolygonPoint::IN; case PolygonSegment::ON: return PolygonPoint::ON; case PolygonSegment::OUT: return PolygonPoint::OUT; - default: abort(); } }