Mk: add lint target and change list print to one-per-line

This commit is contained in:
Franco Fichtner
2016-06-03 11:17:02 +02:00
parent 63a19fd230
commit c1096904e7
2 changed files with 22 additions and 1 deletions
+8 -1
View File
@@ -11,4 +11,11 @@ PLUGIN_DIRS+= ${_${CATEGORY}}
.endfor
list:
@echo ${PLUGIN_DIRS}
.for PLUGIN_DIR in ${PLUGIN_DIRS}
@echo ${PLUGIN_DIR}
.endfor
lint:
.for PLUGIN_DIR in ${PLUGIN_DIRS}
${MAKE} -C ${PLUGIN_DIR} lint
.endfor
+14
View File
@@ -154,4 +154,18 @@ umount: check
clean: check
@git reset -q . && git checkout -f . && git clean -xdqf .
lint: check
find ${.CURDIR}/src \
-name "*.sh" -type f -print0 | xargs -0 -n1 sh -n
find ${.CURDIR}/src \
-name "*.xml" -type f -print0 | xargs -0 -n1 xmllint --noout
find ${.CURDIR}/src \
! -name "*.xml" ! -name "*.xml.sample" ! -name "*.eot" \
! -name "*.svg" ! -name "*.woff" ! -name "*.woff2" \
! -name "*.otf" ! -name "*.png" ! -name "*.js" \
! -name "*.scss" ! -name "*.py" ! -name "*.ttf" \
! -name "*.tgz" ! -name "*.xml.dist" \
-type f -print0 | xargs -0 -n1 php -l
.PHONY: check