0
0
Fork 0

ci: update codeql to v3

Use esp32 target to build code for codeql.
This commit is contained in:
windowsair 2024-01-28 20:25:34 +08:00
parent cc8e819009
commit 3a7ed5922f
1 changed files with 10 additions and 15 deletions

View File

@ -17,8 +17,6 @@ on:
pull_request:
# The branches below must be a subset of the branches above
branches: [ master, develop ]
schedule:
- cron: '16 17 * * 2'
jobs:
analyze:
@ -34,13 +32,13 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
submodules: recursive
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
config-file: ./.github/workflows/codeql/codeql-config.yml
@ -64,16 +62,13 @@ jobs:
- if: matrix.language == 'cpp' || matrix.language == 'c'
name: Build
run: |
ls
sudo apt update
sudo apt install -y gcc git wget make libncurses-dev flex bison python python-setuptools python-serial ninja-build
wget https://dl.espressif.com/dl/xtensa-lx106-elf-linux64-1.22.0-100-ge567ec7-5.2.0.tar.gz
tar -xzf ./xtensa-lx106-elf-linux64-1.22.0-100-ge567ec7-5.2.0.tar.gz
python -m pip install --user -r ./ESP8266_RTOS_SDK/requirements.txt
export IDF_PATH=$PWD/ESP8266_RTOS_SDK
export PATH="$PATH:$PWD/xtensa-lx106-elf/bin"
python ./idf.py fullclean
python ./idf.py build
sudo apt-get install git wget flex bison gperf python3 python3-pip python3-venv cmake ninja-build ccache libffi-dev libssl-dev dfu-util libusb-1.0-0
wget https://github.com/espressif/esp-idf/releases/download/v4.2.2/esp-idf-v4.2.2.zip
unzip esp-idf-v4.2.2.zip
./esp-idf-v4.2.2/install.sh esp32
. ./esp-idf-v4.2.2/export.sh
idf.py set-target esp32
idf.py build
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
uses: github/codeql-action/analyze@v3