Hello Mark,

what you can do is run your cvs update using the exec task and use a nested filterchain do capture output lines with a "U" [1] and apply a regular expression to keep only the path of the file, then save this output into a file. The output file should contain a series of file relative paths in order to be used as input for the includesfile attribute of a patternset.

Something like that (untested) :

<exec executable="cvs" failonerror="true" dir="somerootdir">
<arg value="update"/>
<redirector output="includelist.txt">
<outputfilterchain>
<tokenfilter>
<containsregex pattern="^ U " replace=""/>
</tokenfilter>
</outputfilterchain>
</redirector>
</exec>
<fileset dir="somerootdir">
<patternset includesfile="includelist.txt"/>
</fileset>


Otherwise you can write your own ant task and make this task create either a patternset, a fileset, or a resource collection.

Regards,

Antoine


[1] http://www.cs.utah.edu/dept/old/texinfo/cvs/cvs_toc.html#SEC115

On 12/31/2010 8:17 AM, Mark Lybarger wrote:
i'm using ant to build a project that has been checked out from cvs.  i want
to run a task that uses a fileset of all files changed from cvs.

basically, i'm looking to run a source code formatter on the source files
and only want it to run on files that have changed from the version control.

thanks,
-mark-



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@ant.apache.org
For additional commands, e-mail: user-h...@ant.apache.org

Reply via email to