[drivers] Specifies the name of the drivers driver file #5061
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# Copyright (c) 2006-2024, RT-Thread Development Team | |
# | |
# SPDX-License-Identifier: Apache-2.0 | |
# | |
# Change Logs: | |
# Date Author Notes | |
# 2024-09-04 Supperthomas add cppcheck use the latest release version | |
# | |
name: Static code analysis | |
on: | |
workflow_dispatch: | |
pull_request: | |
branches: | |
- master | |
paths-ignore: | |
- documentation/** | |
- '**/README.md' | |
- '**/README_zh.md' | |
jobs: | |
scancode_job: | |
runs-on: ubuntu-latest | |
name: Static code analysis | |
if: github.repository_owner == 'RT-Thread' | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v3 | |
with: | |
python-version: 3.8 | |
- name: cppcheck | |
shell: bash | |
run: | | |
sudo apt-get update | |
pip install click PyYaml | |
git clone https://github.com/danmar/cppcheck.git | |
cd cppcheck | |
git fetch --tags | |
latest_tag=$(git describe --tags `git rev-list --tags --max-count=1`) | |
echo "Latest release tag: $latest_tag" | |
git checkout $latest_tag | |
mkdir build | |
cd build | |
cmake .. | |
make | |
sudo make install | |
cppcheck --version | |
cd ../../ | |
git remote -v | |
git fetch origin | |
ls | |
git branch -a | |
python tools/ci/cpp_check.py check |