Skip to content

CodeQL

CodeQL #751

# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
#
# ******** NOTE ********
# We have attempted to detect the languages in your repository. Please check
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
#
name: "CodeQL"
on:
push:
branches: [ master ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ master ]
paths-ignore:
- '**/*.md'
- '**/*.txt'
schedule:
- cron: '30 3 * * 1'
jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write
strategy:
fail-fast: false
matrix:
language: [ 'c', 'python' ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
# Learn more:
# https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pyyaml
# tell the CodeQL tool which version of the Python analysis to use
echo "CODEQL_EXTRACTOR_PYTHON_ANALYSIS_VERSION=3.11" >> $GITHUB_ENV
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
- name: Install Embedded Arm Toolchain arm-none-eabi-gcc
uses: carlosperate/[email protected]
with:
release: '13.2.Rel1' # The arm-none-eabi-gcc release to use.
- name: make with GCC
run: |
arm-none-eabi-gcc --version
make -k -w VERBOSE=1
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3