save
This commit is contained in:
11
tools/Cleanup
Normal file → Executable file
11
tools/Cleanup
Normal file → Executable file
@@ -2,8 +2,15 @@
|
||||
|
||||
# Usage: ./Cleanup [FILE]...
|
||||
|
||||
make dist-clean
|
||||
|
||||
lint_file() {
|
||||
cppcheck --enable=all --quiet "$1"
|
||||
local output
|
||||
output=$(clang-tidy "$1" 2>&1 | grep -v -E 'Error while trying to load a compilation database|No compilation database found|fixed-compilation-database:|json-compilation-database:|Running without flags.')
|
||||
if [[ -n "$output" ]]; then
|
||||
echo "[LINT] $1:"
|
||||
echo "$output"
|
||||
fi
|
||||
}
|
||||
|
||||
whitespace_cleanup() {
|
||||
@@ -33,4 +40,4 @@ else
|
||||
for file in $(find yait core -type f \( -name "*.c" -o -name "*.h" \)); do
|
||||
process_file "$file"
|
||||
done
|
||||
fi
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user