java left logo
java middle logo
java right logo
 

Home arrow Other API Tips
 
 
Main Menu
Home
Java Tutorials
Book Reviews
Java SE Tips
Java ME Tips
Java EE Tips
Other API Tips
Java Applications
Java Libraries
Java Games
Java Network
Java Forums
Java Blog




Most Visited Tips
Java SE Tips
Java ME Tips
Java EE Tips
Other API Tips
Java Applications
Java Libraries
Java Games
Book Reviews
Top Rated Tips
Java SE Tips
Java ME Tips
Java EE Tips
Other API Tips
Java Applications
Java Libraries
Java Games
Book Reviews


Statistics
Registered Users: 3919
Java SE Tips: 614
Java ME Tips: 202
Java EE Tips: 183
Other API Tips: 779
Java Applications: 298
Java Libraries: 209
Java Games: 16
Book Reviews:
 
 
 
How to use CvsTagDiff task E-mail
User Rating: / 2
PoorBest 

CvsTagDiff

Description

Generates an XML-formatted report file of the changes between two tags or dates recorded in a CVS repository.

Important: This task needs "cvs" on the path. If it isn't, you will get an error (such as error 2 on windows). If <cvs> doesn't work, try to execute cvs.exe from the command line in the target directory in which you are working.

Parameters

Attribute Description Required
startTag The earliest tag from which diffs are to be included in the report. exactly one of the two.
startDate The earliest date from which diffs are to be included in the report.
accepts all formats accepted by the cvs command for -D date_spec arguments
endTag The latest tag from which diffs are to be included in the report. exactly one of the two.
endDate The latest date from which diffs are to be included in the report.
accepts all formats accepted by the cvs command for -D date_spec arguments
destfile The file in which to write the diff report. Yes

Parameters inherited from the cvs task

Attribute Description Required
compression true, false, or the number 1-9 (corresponding to possible values for CVS -z# argument). Any other value is treated as false No. Defaults to no compression. if passed true, level 3 compression is assumed.
cvsRoot the CVSROOT variable. No
cvsRsh the CVS_RSH variable. No
package the package/module to analyze.
Since ant 1.6 multiple packages separated by spaces are possible. aliases corresponding to different modules are also possible
Yes
quiet suppress informational messages. No, default "false"
port Port used by CVS to communicate with the server. No, default port 2401.
passfile Password file to read passwords from. No, default file ~/.cvspass.
failonerror Stop the buildprocess if the command exits with a returncode other than 0. Defaults to false No

Examples

  <cvstagdiff cvsRoot=":pserver:
 This e-mail address is being protected from spam bots, you need JavaScript enabled to view it
 :/home/cvspublic"
                destfile="tagdiff.xml"

                package="ant"
                startTag="ANT_14"
                endTag="ANT_141"
  />

Generates a tagdiff report for all the changes that have been made in the ant module between the tags ANT_14 and ANT_141. It writes these changes into the file tagdiff.xml.

  <cvstagdiff
                destfile="tagdiff.xml"
                package="ant"
                startDate="2002-01-01"
                endDate="2002-31-01"

  />

Generates a tagdiff report for all the changes that have been made in the ant module in january 2002. In this example cvsRoot has not been set. The current cvsRoot will be used (assuming the build is started from a folder stored in cvs. It writes these changes into the file tagdiff.xml.

  <cvstagdiff
                destfile="tagdiff.xml"
                package="ant jakarta-gump"
                startDate="2003-01-01"
                endDate="2003-31-01"

  />

Generates a tagdiff report for all the changes that have been made in the ant and jakarta-gump modules in january 2003. In this example cvsRoot has not been set. The current cvsRoot will be used (assuming the build is started from a folder stored in cvs. It writes these changes into the file tagdiff.xml.

Generate Report

Ant includes a basic XSLT stylesheet that you can use to generate a HTML report based on the xml output. The following example illustrates how to generate a HTML report from the XML report.

        <style in="tagdiff.xml" 
               out="tagdiff.html" 
               style="${ant.home}/etc/tagdiff.xsl">
          <param name="title" expression="Ant Diff"/>
          <param name="module" expression="ant"/>
          <param name="cvsweb" expression="http://cvs.apache.org/viewcvs/"/>

        </style>

Output

The cvsroot and package attributes of the tagdiff element are new in ant 1.6.
Notes on entry attributes :

AttributeComment
namewhen reporting on one package, the package name is removed from the output
revisionsupplied for files which exist at the end of the reporting period
prevrevisionsupplied for files which exist at the beginning of the reporting period.
Old CVS servers do not supply it for deleted files. CVS 1.12.2 supplies it.

<?xml version="1.0" encoding="UTF-8"?>

<tagdiff startTag="ANT_14" endTag="ANT_141" 
cvsroot=":pserver:
 This e-mail address is being protected from spam bots, you need JavaScript enabled to view it
 :/home/cvspublic" package="ant">
  <entry>
    <file>

      <name>src/main/org/apache/tools/ant/DirectoryScanner.java</name>
      <revision>1.15.2.1</revision>
      <prevrevision>1.15</prevrevision>
    </file>

  </entry>
</tagdiff>

Source: Apache Ant


 Related Tips

 
< Prev   Next >

Page 1 of 0 ( 0 comments )

You can share your information about this topic using the form below!

Please do not post your questions with this form! Thanks.


Name (required)


E-Mail (required)

Your email will not be displayed on the site - only to our administrator
Homepage(optional)



Comment Enable HTML code : Yes No



 
       
         
     
 
 
 
   
 
 
java bottom left
java bottom middle
java bottom right
RSS 0.91 FeedRSS 1.0 FeedRSS 2.0 FeedATOM FeedOPML Feed

Home - About Us - Privacy Policy
Copyright 2005 - 2008 www.java-tips.org
Java is a trademark of Sun Microsystems, Inc.