Using ANT
, how can i make sure that directory exists before attempting to remove it?
As part of my current clean task, i
For this specific case, I'm not going to answer the question "how to find if a directory exists", because that's already been answered, but I'm just going to point out that in your clean task you can use failonerror="false"
to keep the ant task from exiting. This should be suitable in a clean task because if there's nothing to clean, it should not be a problem.
....
This is useful if you don't want to install ant-contrib or can't for some reason.