scripts: Rewrite lint scripts
Rewrite lint scripts to report what they do and if they pass. In the case they fail list the files that caused the failure, except for clang-format, which will be slow to run of every file individually (should just run `make fmt` anyway). Also add a script to run all the lints in order with a single command. Signed-off-by: Tim Crawford <tcrawford@system76.com>
This commit is contained in:
committed by
Jeremy Soller
parent
b03c960b4f
commit
1aadc68257
15
scripts/lint/util.sh
Normal file
15
scripts/lint/util.sh
Normal file
@ -0,0 +1,15 @@
|
||||
#!/usr/bin/env bash
|
||||
# SPDX-License-Identifier: GPL-3.0-only
|
||||
|
||||
passed() {
|
||||
echo -e "\x1B[32mPASSED\x1B[0m"
|
||||
}
|
||||
|
||||
skipped() {
|
||||
local reason=$1
|
||||
echo -e "\x1B[33mSKIPPED\x1B[0m ($reason)"
|
||||
}
|
||||
|
||||
failed() {
|
||||
echo -e "\x1B[31mFAILED\x1B[0m"
|
||||
}
|
Reference in New Issue
Block a user