If you want to use a stable nant version - that can't be easily done. There could be a solution If you download the latest daily build, you'll see support for expressions and functions.
Your condition can be written as: <if test="${string::starts-with(projectFile, 'http://')}"> </if> You can get the latest nightly build at: http://nant.sf.net/builds Jarek ----- Original Message ----- From: "Ryan Cromwell" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, December 31, 2003 4:10 PM Subject: [Nant-users] arg... if task or some other conditional > I have created a script task which populates a property solution.projects with a | delimited string. This is all fine and dandy, but web projects return web urls. I could use DirectoryServices to look up the physical path of the url while still in the script, but i really want to use the NAntContrib iisdirinfo task. I can do this without issue as well, but the problem is I can't figure out how to set a conditional. I need to do the following: > > <foreach item="String" in="${solution.projects}" delim="|" property="projectFile"> > <if propertyTrue="${projectFile} == http*> > <iisdirinfo ... /> > </if> > <do> > <echo message="Creating Build from: ${projectFile}" /> > <style style="${projectTransform}" in="${projectFile}" extension="build" destdir=".\builds" /> > </do> > </foreach> > > > This won't work though, because the foreach item is not a file/directory. Can anyone suggest a way to use the if task or soemthing else. > > > > Thanks everybody > > > > -------------------------------------------------------------------------- ------ > Expand your wine savvy — and get some great new recipes — at MSN Wine. ------------------------------------------------------- This SF.net email is sponsored by: IBM Linux Tutorials. Become an expert in LINUX or just sharpen your skills. Sign up for IBM's Free Linux Tutorials. Learn everything from the bash shell to sys admin. Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click _______________________________________________ Nant-users mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-users ------------------------------------------------------- This SF.net email is sponsored by: IBM Linux Tutorials. Become an expert in LINUX or just sharpen your skills. Sign up for IBM's Free Linux Tutorials. Learn everything from the bash shell to sys admin. Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click _______________________________________________ Nant-users mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-users