How to not increment the build.number in Ant?
Posted
by dacracot
on Stack Overflow
See other posts from Stack Overflow
or by dacracot
Published on 2010-04-07T15:39:10Z
Indexed on
2010/04/07
15:43 UTC
Read the original article
Hit count: 464
I have many targets in my build.xml for Ant. Generally I am running two via a shell script, one to construct the application and one for cleaning up. The shell script checks the exit status of the construction to see if it should clean up or leave the clutter behind so I can determine what went wrong and fix it.
So went all is going well, the majority of the time, Ant is executed once for construction and once for clean up. This results in my build.number being incremented for each execution. So in steady state, my build.number increments by 2.
How can a tell Ant to not increment the build.number? I would do this for clean up as I haven't built anything.
I know the obvious answer of creating a separate script for clean up only, but I'd rather keep the entire build.xml in one file.
© Stack Overflow or respective owner