Thanks, I didn't think of looking into Jelly tags. I'll give it a try. > -----Original Message----- > From: Chuck Daniels [mailto:[EMAIL PROTECTED] > Sent: Thursday, June 10, 2004 3:48 PM > To: Maven Users List > Subject: RE: using filters only when the filters are available > > > You don't want the ant:available task. That task doesn't conditionally > execute it's body as you are thinking. It merely sets a property > to 'true' > if the specified file is available. Instead, you want the jelly > util:available tag, which evaluates its body only if its test condition > evaluates to 'true'. > > > -----Original Message----- > > From: Michael Mattox [mailto:[EMAIL PROTECTED] > > Sent: Thursday, June 10, 2004 2:10 PM > > To: Maven-users > > Subject: using filters only when the filters are available > > > > > > I'm using the filters feature and it works if my filter file is present. > > However, I have a subproject that does not need filtering. Since my > > resources are defined in a master project.xml, I have no choice > but to set > > filtering on for the entire project. However, if this filter > file doesn't > > exist, maven craps out: > > > > BUILD FAILED > > Must specify a file not a directory in the filtersfile > > attribute:D:\projects\MDSP\maven\sources\cs-common\src\conf.dev\de > > v.properti > > es > > File...... D:\projects\MDSP\maven\sources\maven\maven.xml > > Element... ant:filter > > Line...... 8 > > Column.... 72 > > Must specify a file not a directory in the filtersfile > > attribute:D:\projects\MDSP\maven\sources\cs-common\src\conf.dev\de > > v.properti > > es > > > > I tried to be sneaky and use the ANT available task but that > > isn't working: > > > > <preGoal > > name="test:test-resources"> > > <ant:available filepath="${basedir}/src/conf.dev/" > > file="dev.properties"> > > <ant:filter > filtersfile="${basedir}/src/conf.dev/dev.properties" /> > > </ant:available> > > </preGoal> > > > > Is there a way to make the filtering conditional on the filter > file being > > present? Is this a bug? > > > > Regards, > > > > Michael Mattox > > Tech Lead MDSP Communication Services > > Noisy le Grand - MTG - 01 49 31 63 74 > > > > > > -- > > This E-mail is confidential. It may also be legally privileged. > > If you are > > not the addressee you may not copy, forward, disclose or use any > > part of it. > > If you have received this message in error, please delete it and > > all copies > > from your system and notify the sender immediately by return E-mail. > > Internet communications cannot be guaranteed to be timely, > > secure, error or > > virus-free. The sender does not accept liability for any errors > > or omissions. > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > >
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
