For various reasons that I won't go into (I promise it's necessary to do this with the current code base; I know it's goofy), I want to execute a target twice in the same build task.
For example, I want to execute the target foo, then bar, then foo again. This is a simplified version of what I already tried:
<target name="foo">
...
</target>
<target name="bar" depends="foo">
...
</target>
<target name="project" depends="foo,bar">
...
</target>
In this case when executing the project target, foo only ran once. I also tried getting rid of the depends attribute on the bar target and making the project's depends attribute "foo,bar,foo", but still the same result.
Is there a way to force a task to execute, even if it's already successfully completed? Or is there a better way to go about this?