views:

235

answers:

3

I am thinking of running this custom targets to find out more about my project build status - jalopy - jdepend - cvs tagdiff report - custom task for NoUnit - generate UML diagram. ESS-Model

What are your views?

+1  A: 

I think that it's a great idea and use it myself. That way I'll never forget to run it.

I also keep the reports for a decent amount of time and eventually create a spreadsheet of "progress".

In your main ant task - call another task to do "whatever"

and JDepend.xml ...

<target name="statsAll">
 <!-- master file that describes where everything is -->
 <property file="./ant/ant-global.properties" prefix="ant-global" />
 <tstamp>
       <format property="gen.time" pattern="yyyyMMdd_hh"/>
 </tstamp>
 <echo message="LOG:./ant/logs/jdepend.${version.FILETAG}.${gen.time}.rpt"/>
 <!-- generate stats to see if we're improving -->
 <jdepend 
  outputfile="./ant/logs/jdepend.${version.FILETAG}.${gen.time}.rpt" >
  <exclude name="java.*"/>
  <exclude name="javax.*"/>
 <classespath>
 <pathelement location="./jar" />
   </classespath>
   <classpath location="./jar" />
 </jdepend>
</target>

<target name="doJDepend" depends="getVersion,statsAll">
 <echo message="FTP'ing report"/>
    <ftp verbose="yes" passive="yes" depends="yes"
        remotedir="/videojet/metrics" server="xxxxx"
        userid="xxxx" password="xxxxx"
        binary="no"
        systemTypeKey="UNIX">
     <fileset dir="./ant/logs/" casesensitive="no">
       <include name="**/jdepend.${version.FILETAG}*.rpt"/>
       <exclude name="**/*.txt"/>
     </fileset>
    </ftp>
</target>

Magic build machine

jim
A: 

I second the 'good idea' part, although for a project of reasonable size you might want to make it part of an automated build, like one of the CI Servers (Bamboo, Contiuum).

You might also consider a code coverage tool to see how your test coverage is going.

This will ensure the reports get run on a regular basis, could give you somewhere to publish them and won't slow down the developer's quick turnaround development cycle.

Ken Gentle
A: 

I also think some reports about your project are a good idea. My template-project for an ant-build-script (Antiplate) has at the moment the following reports: Junitreport, emma-report, PMD, CPD and Checkstyle. I'm thinking about including a JDepend-report.

At work we use these templates and using Hudson as continuous-integration-system. Hudson creates wonderful graphs for these reports and how the measures changed with the builds.

Mnementh