Skip to content

Commit 97a1735

Browse files
committed
[CI] Enable NOLINT CI check
1 parent 2914e47 commit 97a1735

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

.github/workflows/static-analysis-pr.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,3 +78,21 @@ jobs:
7878
run: |
7979
echo "clang-tidy run has failed. See previous 'Run clang-tidy' stage logs"
8080
exit 1
81+
nolint-check:
82+
runs-on: ubuntu-24.04
83+
steps:
84+
- uses: actions/checkout@v4
85+
- name: Search for NOLINT
86+
run: |
87+
export CHANGED_FILES="$(git diff --name-only origin/${{ github.event.pull_request.base.ref }} HEAD | grep '^tasks/')"
88+
if [ -z "$CHANGED_FILES" ]; then
89+
echo "No changed files in tasks directory."
90+
exit 0
91+
fi
92+
for file in $CHANGED_FILES; do
93+
if grep -n "NOLINT" "$file"; then
94+
echo "::error::Found 'NOLINT' in $file."
95+
exit 1
96+
fi
97+
done
98+
echo "No 'NOLINT' markers found in changed files."

0 commit comments

Comments
 (0)