summaryrefslogtreecommitdiffstats
path: root/admin
diff options
context:
space:
mode:
Diffstat (limited to 'admin')
-rw-r--r--admin/findallphp8
-rw-r--r--admin/fixperms2
-rw-r--r--admin/runtests6
-rw-r--r--admin/syntaxcheck5
4 files changed, 20 insertions, 1 deletions
diff --git a/admin/findallphp b/admin/findallphp
new file mode 100644
index 0000000..59a7306
--- /dev/null
+++ b/admin/findallphp
@@ -0,0 +1,8 @@
+#!/usr/bin/env bash
+
+find Auth Tests \
+ -name _darcs -prune -o \
+ \( -type f \
+ -a -name \*.php \
+ -a ! -name .\* \
+ \)
diff --git a/admin/fixperms b/admin/fixperms
index 2b710d1..0ea0944 100644
--- a/admin/fixperms
+++ b/admin/fixperms
@@ -10,4 +10,6 @@ admin/makedoc.sh
admin/mathlib
admin/prepare-release
admin/runtests
+admin/findallphp
+admin/syntaxcheck
EOF
diff --git a/admin/runtests b/admin/runtests
index 6629235..920a873 100644
--- a/admin/runtests
+++ b/admin/runtests
@@ -8,6 +8,10 @@ test_import () {
./admin/checkimports
}
+test_syntax () {
+ ./admin/syntaxcheck
+}
+
test_tabs () {
/usr/bin/env bash "$HERE/notabs"
}
@@ -40,7 +44,7 @@ test_php () {
fi
}
-tests="tabs longlines nobadbraces nobadcase opentag docblocks php import"
+tests="syntax tabs longlines nobadbraces nobadcase opentag docblocks php import"
failures=
diff --git a/admin/syntaxcheck b/admin/syntaxcheck
new file mode 100644
index 0000000..f94b7fa
--- /dev/null
+++ b/admin/syntaxcheck
@@ -0,0 +1,5 @@
+#!/usr/bin/env bash
+
+for file in `./admin/findallphp`
+ do php -l $file
+done