Remove duplicate files with ant?

Is there a way to remove duplicate files using ant? In particular, if I have one file name in two different output directories, I want to remove it from the second directory.

+5
source share
1 answer

I think I came up with a solution.

<target name="delete-duplicates">
    <delete>
        <fileset dir="delete-here" includes="**/*">
            <present targetdir="if-present-here" />
        </fileset>
    </delete>
</target>
+10
source

All Articles