Skip to content

Commit

Permalink
github action: fix placement
Browse files Browse the repository at this point in the history
  • Loading branch information
0xc0170 committed Apr 20, 2022
1 parent e86965c commit b455f9f
Showing 1 changed file with 7 additions and 11 deletions.
18 changes: 7 additions & 11 deletions .github/workflows/basic_checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ jobs:
uses: actions/checkout@v3
with:
fetch-depth: 0
run: |
git config --global --add safe.directory "$GITHUB_WORKSPACE"


-
name: install dependencies
Expand All @@ -34,7 +33,7 @@ jobs:
run: |
set -x
mkdir -p SCANCODE
git config --global --add safe.directory "$GITHUB_WORKSPACE"
git diff --name-only --diff-filter=d origin/${GITHUB_BASE_REF} \
| ( grep '.\(c\|cpp\|h\|hpp\|py\)$' || true )
echo $?
Expand Down Expand Up @@ -65,12 +64,11 @@ jobs:
uses: actions/checkout@v3
with:
fetch-depth: 0
run: |
git config --global --add safe.directory "$GITHUB_WORKSPACE"

-
name: include check
run: |
git config --global --add safe.directory "$GITHUB_WORKSPACE"
# checks mbed.h is not included in MbedOS files except in tests
! git grep '^#include\s["'"']mbed.h['"'"]$' -- '*.c' '*.h' '*.cpp' '*.hpp' \
':!*platform_mbed.h' ':!*TESTS/*' ':!TEST_APPS/' ':!UNITTESTS/' \
Expand All @@ -88,12 +86,11 @@ jobs:
uses: actions/checkout@v3
with:
fetch-depth: 0
run: |
git config --global --add safe.directory "$GITHUB_WORKSPACE"

-
name: UTF-8 Check
run: |
git config --global --add safe.directory "$GITHUB_WORKSPACE"
# Make sure we're not introducing any text which is not UTF-8 encoded
git diff origin/${GITHUB_BASE_REF} -U0 | ( grep -a '^+' || true ) | ( ! grep -axv '.*' )
Expand All @@ -102,6 +99,7 @@ jobs:
name: astyle checks
run: |
set -x
git config --global --add safe.directory "$GITHUB_WORKSPACE"
git diff --name-only --diff-filter=d origin/${GITHUB_BASE_REF} \
| ( grep '.*\.\(c\|cpp\|h\|hpp\)$' || true ) \
| ( grep -v -f .codecheckignore || true ) \
Expand Down Expand Up @@ -193,13 +191,12 @@ jobs:
uses: actions/checkout@v3
with:
fetch-depth: 0
run: |
git config --global --add safe.directory "$GITHUB_WORKSPACE"

-
name: validate pins
run: |
set -x
git config --global --add safe.directory "$GITHUB_WORKSPACE"
git diff --name-only --diff-filter=d origin/${GITHUB_BASE_REF} \
| ( grep '.*[\\|\/]PinNames.h$' || true ) \
| while read file; do python ./hal/tests/pinvalidate/pinvalidate.py -vvvfp "${file}"; done
Expand Down Expand Up @@ -248,13 +245,12 @@ jobs:
uses: actions/checkout@v3
with:
fetch-depth: 0
run: |
git config --global --add safe.directory "$GITHUB_WORKSPACE"

-
name: frozen tool check
run: |
set -x
git config --global --add safe.directory "$GITHUB_WORKSPACE"
git diff --name-only origin/${GITHUB_BASE_REF} \
| egrep \
-e "^tools/build_api*" \
Expand Down

0 comments on commit b455f9f

Please sign in to comment.