mirror of
https://gitlab.com/niansa/SomeBot.git
synced 2025-03-06 20:48:26 +01:00
51 lines
1.1 KiB
YAML
51 lines
1.1 KiB
YAML
name: "CodeQL"
|
|
|
|
on:
|
|
push:
|
|
branches: [ master ]
|
|
paths:
|
|
- "**/Source/*"
|
|
- "**/Source/**/*"
|
|
|
|
env:
|
|
BUILD_TYPE: Release
|
|
|
|
jobs:
|
|
analyze:
|
|
name: Analyze
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
language: [ 'cpp' ]
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v2
|
|
with:
|
|
submodules: true
|
|
|
|
- name: Install Ninja
|
|
uses: seanmiddleditch/gha-setup-ninja@master
|
|
|
|
- name: Initialize CodeQL
|
|
uses: github/codeql-action/init@v2
|
|
with:
|
|
languages: ${{ matrix.language }}
|
|
|
|
- name: Create Build Environment
|
|
run: cmake -E make_directory ${{runner.workspace}}/build
|
|
|
|
- name: Configure CMake
|
|
shell: bash
|
|
working-directory: ${{runner.workspace}}/build
|
|
run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE -G Ninja
|
|
|
|
- name: Build
|
|
working-directory: ${{runner.workspace}}/build
|
|
shell: bash
|
|
run: cmake --build . --config $BUILD_TYPE
|
|
|
|
- name: Perform CodeQL Analysis
|
|
uses: github/codeql-action/analyze@v2
|