mirror of
https://github.com/FeralInteractive/gamemode.git
synced 2025-06-26 17:31:45 +02:00
Add clang analyzer check using scan-build
This commit is contained in:
14
scripts/static-analyser-check.sh
Executable file
14
scripts/static-analyser-check.sh
Executable file
@ -0,0 +1,14 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Exit on failure
|
||||
set -e
|
||||
|
||||
# Build directly
|
||||
cd build/
|
||||
|
||||
# Collect scan-build output
|
||||
ninja scan-build | tee /tmp/scan-build-results.txt
|
||||
|
||||
# Invert the output - if this string exists it's a fail
|
||||
! grep -E '[0-9]+ bugs? found.' /tmp/scan-build-results.txt
|
||||
|
Reference in New Issue
Block a user