mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-12-08 12:45:22 -05:00
Add uncrustify github workflow (#659)
* Add uncrustify github workflow * Fix exclusion pattern * fix find expression * exclude uncrustify files * Uncrustify common demo and test files * exlude white space checking files * Fix EOL whitespace checker * Remove whitespaces from EOL * Fix space at EOL * Fix find spaces at EOL Co-authored-by: Archit Aggarwal <architag@amazon.com>
This commit is contained in:
parent
dd80d615b5
commit
ae92d8c6ee
191 changed files with 17540 additions and 17102 deletions
34
.github/workflows/ci.yml
vendored
34
.github/workflows/ci.yml
vendored
|
|
@ -24,6 +24,38 @@ jobs:
|
|||
run: |
|
||||
git-secrets --register-aws
|
||||
git-secrets --scan
|
||||
|
||||
formatting:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Install Uncrustify
|
||||
run: sudo apt-get install uncrustify
|
||||
- name: Run Uncrustify
|
||||
run: |
|
||||
uncrustify --version
|
||||
find FreeRTOS/Demo/Common FreeRTOS/Test \( -name ethernet -o -name drivers -o -path 'FreeRTOS/Test/CMock/CMock' \) -prune -false -o -name "*.[hc]" -exec uncrustify --check -c tools/uncrustify.cfg {} +
|
||||
- name: Check For Trailing Whitespace
|
||||
run: |
|
||||
set +e
|
||||
ERROR=0
|
||||
find . \( -name '.git' -o -path "./FreeRTOS/Test/CBMC/patches" -o -path "./FreeRTOS-Plus" -o -path "./FreeRTOS/Source" -o -path "./FreeRTOS/Test/CMock/CMock" -o -path "./FreeRTOS/Demo" \) -prune -false -o -type f -a -name "*" -exec grep -In -e "[[:blank:]]$" {} +
|
||||
if [ "$?" = "0" ]; then
|
||||
echo "Files have trailing whitespace."
|
||||
ERROR=1
|
||||
fi
|
||||
|
||||
find FreeRTOS/Demo/Common \( -name "ethernet" \) -prune -o -false -o -type f -a -name "*" -exec grep --color=yes -In -e "[[:blank:]]$" {} +
|
||||
if [ "$?" = "0" ]; then
|
||||
echo "Files have trailing whitespace."
|
||||
exit 1
|
||||
else
|
||||
if [ "$ERROR" -eq "1" ]; then
|
||||
exit 1
|
||||
fi
|
||||
exit 0
|
||||
fi
|
||||
|
||||
doxygen:
|
||||
runs-on: ubuntu-20.04
|
||||
steps:
|
||||
|
|
@ -53,7 +85,7 @@ jobs:
|
|||
- name: Upload doxygen artifact if main branch
|
||||
if: success() && ( github.ref == 'refs/heads/main' || github.ref == 'refs/heads/release-candidate' )
|
||||
env:
|
||||
GIT_SHA:
|
||||
GIT_SHA:
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: doxygen.zip-${{ github.sha }}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue