Skip to content

CodeQL

CodeQL #80

name: "CodeQL"
on:
workflow_dispatch:
pull_request:
branches: [ master ]
schedule:
- cron: '00 21 * * 5'
env:
BUILD_TYPE: Release
jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write
strategy:
fail-fast: false
matrix:
language: [ 'cpp' ]
steps:
- name: Checkout repository
uses: actions/checkout@v4
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
- name: Install dependency
run: sudo apt-get -y install ninja-build libicu-dev libxml2-dev zlib1g-dev libminizip-dev
- name: Create Build folder
run: mkdir -p _build
- name: Configure CMake
run: >
cmake -S . -B _build -G "Ninja"
-DCMAKE_BUILD_TYPE=$BUILD_TYPE
-DCOLORER_BUILD_TEST=OFF
-DCOLORER_USE_VCPKG=OFF
-DCOLORER_BUILD_ARCH=x64
- name: Build
run: cmake --build _build --config $BUILD_TYPE -j 2
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3