Merge pull request #246 from ityuhui/yh-versioning-doc-0910 #100
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
name: Code Check | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
types: [assigned, opened, synchronize, reopened] | |
jobs: | |
code-static-check: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Prepare | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y cppcheck | |
- name: Code static check for config | |
run: sh ./code-check/code-static-check.sh ./kubernetes/config/ | |
- name: Code static check for examples | |
run: sh ./code-check/code-static-check.sh ./examples/ | |
code-style-check: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Prepare | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y indent | |
- name: Code style check for config | |
run: | | |
find ./kubernetes/config/ -type f -regextype posix-extended -regex ".*\.(c|h)" -exec sh ./code-check/code-style-check.sh {} \; | |
find ./kubernetes/config/ -type f -regextype posix-extended -regex ".*\.(c|h)" -exec diff {} {}~ \; | |
- name: Code style check for examples | |
run: | | |
find ./examples/ -type f -regextype posix-extended -regex ".*\.(c|h)" -exec sh ./code-check/code-style-check.sh {} \; | |
find ./examples/ -type f -regextype posix-extended -regex ".*\.(c|h)" -exec diff {} {}~ \; |