Add basic qml linter config
This commit is contained in:
parent
2b1c9af311
commit
d0c43eb872
3 changed files with 77 additions and 1 deletions
|
|
@ -8,6 +8,7 @@
|
|||
set -eu
|
||||
|
||||
FILES=$(find src -type f \( -iname "*.cpp" -o -iname "*.h" \))
|
||||
QML_FILES=$(find resources/qml -type f \( -iname "*.qml" \))
|
||||
|
||||
for f in $FILES
|
||||
do
|
||||
|
|
@ -15,3 +16,11 @@ do
|
|||
done;
|
||||
|
||||
git diff --exit-code
|
||||
|
||||
if command -v /usr/lib64/qt6/bin/qmllint &> /dev/null; then
|
||||
/usr/lib64/qt6/bin/qmllint $QML_FILES
|
||||
elif command -v /usr/lib/qt6/bin/qmllint &> /dev/null; then
|
||||
/usr/lib/qt6/bin/qmllint $QML_FILES
|
||||
else
|
||||
echo "No qmllint found, skipping check!"
|
||||
fi
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue