![JAR search and dependency download from the Maven repository](/logo.png)
no.tsl2.nano.h5.2.5.3.source-code.code-analysis.xml Maven / Gradle / Ivy
<?xml version="1.0" encoding="UTF-8"?> <!-- Starts static code analysis for a given project. 'basedir' should be inherited from calling Project and should point to the main directory of that project. created by Thomas Schneider / 2010 --> <project default="all" name="analysis"> <property name="analysis.home" value="${basedir}/../tsl2.nano.common"/> <property name="target.ci" value="target/ci" /> <target name="init"> <mkdir dir="${target.ci}"/> </target> <!-- Allgemeine Konfiguration --> <target name="all" depends="init,findbugs,pmd,cpd,checkstyle" /> <path id="ana.java.src.path"> <fileset id="ana.java.src.dir" dir="${basedir}"> <include name="**/*.java" /> </fileset> </path> <!-- Findbugs --> <echo>Doing static code analysis on: ${basedir}</echo> <property name="findbugs.home" value="${analysis.home}/ci/findbugs" /> <path id="findbugs-jar"> <pathelement path="${findbugs.home}/findbugs-ant.jar" /> </path> <taskdef name="findbugs" classname="edu.umd.cs.findbugs.anttask.FindBugsTask" classpathref="findbugs-jar" /> <target name="findbugs" depends="init" unless="analysis.disable.findbugs"> <findbugs home="${findbugs.home}" output="xml:withMessages" outputFile="${target.ci}/findbugs.xml"> <sourcePath path="${basedir}" /> <class location="bin" /> </findbugs> </target> <!-- PMD --> <path id="pmd.classpath"> <pathelement location="${build}" /> <fileset dir="${analysis.home}/ci/pmd"> <include name="*.jar" /> </fileset> </path> <taskdef name="pmd" classname="net.sourceforge.pmd.ant.PMDTask" classpathref="pmd.classpath" /> <target name="pmd" depends="init" unless="analysis.disable.pmd"> <pmd rulesetfiles="rulesets/favorites.xml"> <formatter type="xml" toFile="${target.ci}/pmd.xml" /> <fileset refid="ana.java.src.dir" /> </pmd> </target> <!-- CPD --> <taskdef name="cpd" classname="net.sourceforge.pmd.cpd.CPDTask" classpathref="pmd.classpath" /> <target name="cpd" depends="init" unless="analysis.disable.cpd"> <cpd minimumTokenCount="100" ignoreLiterals="true" encoding="ISO-8859-15" format="xml" language="java" outputFile="${target.ci}/cpd.xml"> <fileset refid="ana.java.src.dir" /> </cpd> </target> <!-- Checkstyle --> <taskdef resource="checkstyletask.properties" classpath="${analysis.home}/ci/checkstyle/checkstyle-5.3-all.jar" /> <target name="checkstyle" depends="init" unless="analysis.disable.checkstyle"> <checkstyle config="${analysis.home}/ci/checkstyle/sun_checks.xml" failOnViolation="false"> <fileset refid="ana.java.src.dir" /> <formatter type="xml" toFile="${target.ci}/checkstyle.xml" /> </checkstyle> </target> </project>
© 2015 - 2025 Weber Informatics LLC | Privacy Policy