Skip to content

Commit

Permalink
Update the ci.yml file, swap from lexicon.txt to cSpellWords.txt, use…
Browse files Browse the repository at this point in the history
… new version of CI workflow file
  • Loading branch information
Skptak committed Dec 12, 2023
1 parent 99b1228 commit 65bd399
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 1,012 deletions.
32 changes: 16 additions & 16 deletions .github/.cSpellWords.txt
Original file line number Diff line number Diff line change
@@ -1,34 +1,34 @@
cbmc
CBMC
cbor
CBOR
CMOCK
CMock
CSDK
cmock
Cmock
CMock
CMOCK
coremqtt
coverity
Coverity
CSDK
ctest
DCMOCK
DNDEBUG
DUNITY
MISRA
MQTT
Misra
UNACKED
UNSUB
UNSUBACK
Wunused
cbmc
cbor
cmock
coremqtt
coverity
ctest
getpacketid
isystem
lcov
misra
Misra
MISRA
MQTT
mypy
pylint
pytest
pyyaml
sinclude
UNACKED
UNSUB
UNSUBACK
unsubscriptions
utest
Wunused
89 changes: 29 additions & 60 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,80 +7,49 @@ on:
branches: ["**"]

jobs:
spell-check:
runs-on: ubuntu-latest
formatting:
runs-on: ubuntu-20.04
steps:
- name: Checkout Parent Repo
uses: actions/checkout@v2
with:
ref: main
repository: FreeRTOS/CI-CD-Github-Actions
path: actions
- name: Clone This Repo
uses: actions/checkout@v2
with:
ref: ${{ github.event.pull_request.head.sha }}
path: ./NXPRef
- name: Install spell
run: |
sudo apt-get install spell
sudo apt-get install util-linux
- name: Check spelling
run: |
PATH=$PATH:actions/spellings/tools
# Make sure that the portable directory is not included in the spellcheck.
sed -i "s/-iname \\\\\*.\[ch\] -o/-not -path \\\*Middleware\\\\\/NXP\\\* -iname \\\\\*.\[ch\] -o/g" actions/spellings/tools/find-unknown-comment-words
find-unknown-comment-words --directory NXPRef/ --lexicon NXPRef/lexicon.txt
if [ "$?" = "0" ]; then
exit 0
else
exit 1
fi
- uses: actions/checkout@v3
- name: Check Formatting of Files
uses: FreeRTOS/CI-CD-Github-Actions/formatting@main

spell-check:
runs-on: ubuntu-latest
steps:
- name: Clone This Repo
uses: actions/checkout@v3
- name: Run spellings check
uses: FreeRTOS/CI-CD-Github-Actions/spellings@main

link-verifier:
runs-on: ubuntu-latest
steps:
- name: Clone This Repo
uses: actions/checkout@v2
- name: Run link verifier
uses: actions/checkout@v3
- name: Link Verification
uses: FreeRTOS/CI-CD-Github-Actions/link-verifier@main
with:
path: ./
include-file-types: .c,.h,.md,.dox
exclude-dirs: NXP

formatting:
verify-manifest:
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 -not -path ".*/Middleware/NXP*" -iname "*.[hc]" -exec uncrustify --check -c ./uncrustify.cfg {} +
if [ "$?" = "0" ]; then
exit 0
else
echo -e "\033[31;1;43mFormatting check (using Uncrustify) failed...\033[0m"
exit 1
fi
- name: Check For Trailing Whitespace
run: |
set +e
grep --exclude-dir="NXP" --exclude="README.md" -rnI -e "[[:blank:]]$" .
if [ "$?" = "0" ]; then
echo "Files have trailing whitespace."
exit 1
else
exit 0
fi
- uses: actions/checkout@v3
with:
submodules: true
fetch-depth: 0

- name: Run manifest verifier
uses: FreeRTOS/CI-CD-GitHub-Actions/manifest-verifier@main
with:
path: ./
fail-on-incorrect-version: true

git-secrets:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Checkout awslabs/git-secrets
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
repository: awslabs/git-secrets
ref: master
Expand Down
Loading

0 comments on commit 65bd399

Please sign in to comment.