Mercurial > public > develkit
diff sonar-ant.xml @ 24:a63acb4e09f8
inital sonar-ant script to publish metrics to Sonar server
author | smith@nwoca.org |
---|---|
date | Tue, 05 Apr 2011 16:28:00 -0400 |
parents | |
children | e6fd2f1eba13 |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/sonar-ant.xml Tue Apr 05 16:28:00 2011 -0400 @@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="UTF-8"?> +<project name="sonar-project-tasks" default="" basedir="." + xmlns:ivy="antlib:fr.jayasoft.ivy.ant" + xmlns:sonar="antlib:org.sonar.ant" + xmlns:ssdt="http://www.ssdt-ohio.org/ant/common"> + + <description>Sonar Ant tasks</description> + + <property name="ssdt.sonar.jar.src" value="http://ivy.ssdt.nwoca.org/repository/sonar/sonar-ant-task.jar"/> + + <ssdt:fetch dest="${user.home.ant.lib}/sonar.jar" + src="${ssdt.sonar.jar.src}"/> + + <taskdef uri="antlib:org.sonar.ant" resource="org/sonar/ant/antlib.xml"/> + + <property name="sonar.host.url" value="http://localhost:9000" /> + <property name="sonar.language" value="grvy"/> + + + <target name="sonar" depends="project.init,ivy-info"> + <sonar:sonar + workDir="${build.dir}/sonar" + key="${ivy.project.organisation}:${ivy.project.module}" + version="${project.version}" > + <sources> + <path location="${src.dir}" /> + </sources> + <property key="sonar.projectName" value="${ivy.project.module}"/> + <property key="sonar.language" value="${sonar.language}" /> + <property key="sonar.dynamicAnalysis" value="reuseReports" /> + <property key="sonar.surefire.reportsPath" value="${build.test.results.dir}"/> + <tests> + <path location="${test.dir}" /> + </tests> + <binaries> + <path location="${build.dir}/classes" /> + </binaries> + </sonar:sonar> + </target> + +</project>