You just do...
<tempfile property="my-temp" suffix=""/>
<mkdir dir="${my-temp}"/>
The creates the directory in basedir, and by using tempfile you guarantees
that the directory does not already exist. But if the directory did already
exists, mkdir will do nothing, there is no need to check first.
(BTW thanks for the XSLT FAQ. I spend a lot of time out there)
On Tue, Apr 24, 2012 at 10:44 AM, Dave Pawson <[email protected]> wrote:
> I need a temporary directory.
>
> What's the 'ant speak' for
>
> property name='my-temp' if directory exists (my-temp) then my-temp
> else mkdir 'my-temp'
>
> I hope that's clear?
> In bash it might be
>
> #check/create fo directory for output, per font
> if [[ ! -d ${here}/fo ]]
> then
> mkdir ${here}/fo
>
> fi
>
>
>
> TIA
>
> --
> Dave Pawson
> XSLT XSL-FO FAQ.
> Docbook FAQ.
> http://www.dpawson.co.uk
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>
--
Harold PUTMAN
Web Technology Specialist
*Lexmark International, Inc. <http://www.lexmark.com>*
740 W New Circle Rd.
Lexington, KY 40550
+1(859) 232-2839
[email protected]