From 11d3f960617b0a96b9a726f3013ff30c95e3032a Mon Sep 17 00:00:00 2001 From: jeefo Date: Mon, 16 Nov 2020 14:42:37 +0300 Subject: [PATCH] Create codeql.yml --- .github/workflows/codeql.yml | 40 ++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 .github/workflows/codeql.yml diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml new file mode 100644 index 0000000..58246a8 --- /dev/null +++ b/.github/workflows/codeql.yml @@ -0,0 +1,40 @@ +name: "CodeQL" + +on: + push: + branches: [master] + pull_request: + branches: [master] + schedule: + - cron: '0 19 * * 0' + +jobs: + analyze: + name: Analyze + runs-on: self-hosted + + strategy: + fail-fast: false + matrix: + language: ['cpp'] + + steps: + - name: Checkout repository + uses: actions/checkout@v2 + with: + fetch-depth: 2 + + - run: git checkout HEAD^2 + if: ${{ github.event_name == 'pull_request' }} + + - name: Initialize CodeQL + uses: github/codeql-action/init@v1 + with: + languages: ${{ matrix.language }} + + - run: | + meson setup codeql + ninja -C codeql -v + + - name: Perform CodeQL Analysis + uses: github/codeql-action/analyze@v1