Adding a static analyzer.

This commit is contained in:
Luigi Rosso
2020-07-23 11:01:08 -07:00
parent b28d43f926
commit 69f991422d
2 changed files with 23 additions and 1 deletions

5
.gitignore vendored
View File

@@ -50,4 +50,7 @@ pubspec.lock
*.DS_Store
# Generated docs
rive/docs
rive/docs
# Analysis results
dev/analysis_report

19
dev/analyze.sh Executable file
View File

@@ -0,0 +1,19 @@
#!/bin/bash
# install scan-build
if ! command -v scan-build &> /dev/null
then
if ! command -v pip &> /dev/null
then
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
python3 get-pip.py
fi
pip install scan-build
fi
cd test
premake5 clean || exit 1
premake5 gmake || exit 1
scan-build -o ../analysis_report/ make -j7 || exit 1
premake5 clean