summaryrefslogtreecommitdiffstats
path: root/build
diff options
context:
space:
mode:
Diffstat (limited to 'build')
-rw-r--r--build/build.xml20
1 files changed, 20 insertions, 0 deletions
diff --git a/build/build.xml b/build/build.xml
index 0f9d3605da1..265beb4bccf 100644
--- a/build/build.xml
+++ b/build/build.xml
@@ -40,6 +40,26 @@
</fileset>
</apply>
+
+ <!-- this looks for @brief and @returns annotation in PHP files and fails if it found some -->
+ <apply executable="egrep" failonerror="false" resultproperty="grepReturnCode">
+ <arg value="-rsHn" />
+ <arg value="@brief|@returns" />
+
+ <fileset dir="${basedir}/build">
+ <include name="**/*.php" />
+ <exclude name="**/3rdparty/**" />
+ <exclude name="**/l10n/**" />
+ </fileset>
+ </apply>
+
+ <!-- fail if grep has found something -->
+ <fail message="Please remove @returns and @brief annotations for PHPDoc (listed above)">
+ <condition>
+ <equals arg1="0" arg2="${grepReturnCode}"/>
+ </condition>
+ </fail>
+
</target>
<!-- javascript lint -->