mirror of
https://github.com/Karaka-Management/Build.git
synced 2026-01-11 11:48:40 +00:00
More check fixes
This commit is contained in:
parent
57585e9207
commit
17e1afe276
|
|
@ -2,24 +2,24 @@
|
||||||
|
|
||||||
hasInvalidPhpSyntax() {
|
hasInvalidPhpSyntax() {
|
||||||
# php lint
|
# php lint
|
||||||
php -l "$1"
|
$(php -l "$1" > /dev/null)
|
||||||
if [ $? -ne 0 ]; then
|
if [[ $? != 0 ]]; then
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# phpcs
|
# phpcs
|
||||||
php -d memory_limit=4G ${rootpath}/vendor/bin/phpcs --standard="${rootpath}/Build/Config/phpcs.xml" --encoding=utf-8 -n -p "$1"
|
$(php -d memory_limit=4G ${rootpath}/vendor/bin/phpcs --standard="${rootpath}/Build/Config/phpcs.xml" --encoding=utf-8 -n -p "$1" > /dev/null)
|
||||||
if [ $? -ne 0 ]; then
|
if [[ $? != 0 ]]; then
|
||||||
return 2
|
return 2
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# phpmd
|
# phpmd
|
||||||
php -d memory_limit=4G ${rootpath}/vendor/bin/phpmd "$1" text ${rootpath}/Build/Config/phpmd.xml --exclude *tests* --minimumpriority 1
|
$(php -d memory_limit=4G ${rootpath}/vendor/bin/phpmd "$1" text ${rootpath}/Build/Config/phpmd.xml --exclude *tests* --minimumpriority 1)
|
||||||
if [ $? -ne 0 ]; then
|
if [[ $? != 0 ]]; then
|
||||||
return 3
|
return 3
|
||||||
fi
|
fi
|
||||||
|
|
||||||
return 0;
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
hasInvalidHtmlTemplateContent() {
|
hasInvalidHtmlTemplateContent() {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user