maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pete <peteli...@gmail.com>
Subject Re: maven-antrun-plugin - <if> issue
Date Tue, 02 May 2006 12:14:43 GMT
I am using Antrun with antcontrib if's as follows :-

<configuration>
 <tasks>
  <taskdef resource="net/sf/antcontrib/antcontrib.properties">
   <classpath>
    <pathelement location="../../src/ant/lib/optional.jar"/>
    <pathelement location="../../src/ant/lib/ant-contrib-1-0b1.jar"/>
   </classpath>
  </taskdef>
  <if>
      .....

this works fine.


On 01/05/06, Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc.
at Cisco) <jpadmana@cisco.com> wrote:
>
>
> I did try that. Copied the ant-contrib jar to my local repository and
> added the dependency.
> But still didn't work :-(
> Same error msg that task if cannot be found.
>
> Thanks
> -Jagan
>
> -----Original Message-----
> From: Daniel Kulp [mailto:dan@kulp.com]
> Sent: Monday, May 01, 2006 5:37 AM
> To: users@maven.apache.org
> Cc: Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc. at
> Cisco)
> Subject: Re: maven-antrun-plugin - <if> issue
>
>
>
> You could try using the antcontrib stuff from:
> http://ant-contrib.sourceforge.net/tasks/tasks/index.html
>
> There is an if task, etc....    I don't think it's available on ibiblio,
>
> so you would either need to put it in your own repository or file the
> right jira issue to get it added.
>
> Dan
>
>
>
> On Monday 01 May 2006 06:51, Jagan Padmanabha Pillai -X (jpadmana -
> Insight Solutions, Inc. at Cisco) wrote:
> > I have some ant tasks which needs to be executed only if packaging is
> > "ejb".
> > But don't want to repeat this code in all ejb POMs.
> > So thought of adding this to a parent POM, which all other modules
> > (many components- ejbs, wars, jars, ears, etc) inherit.
> >
> > So in order to make sure that this gets executed only for ejb
> > projects, I want to check, <tasks> <if>  <equals
> > arg1="${project.packaging}" arg2="pom" />  <then>
> >    ant tasks details...
> >  </then>
> > </if>
> >
> > Does this makes sense ?
> >
> > -Jagan
> >
> >
> > -----Original Message-----
> > From: Kenney Westerhof [mailto:kenney@apache.org]
> > Sent: Monday, May 01, 2006 2:42 AM
> > To: Maven Users List
> > Subject: Re: maven-antrun-plugin - <if> issue
> >
> > On Mon, 1 May 2006, Jagan Padmanabha Pillai -X (jpadmana - Insight
> > Solutions, Inc. at Cisco) wrote:
> >
> > Can you give me an example of what you're doing? A POM snippet for
> > example?
> >
> > It's true that
> >       <tasks if="..." unless="...">
> >
> > does not work. It's on my todo list.
> >
> > -- Kenney
> >
> > > Hi,
> > >
> > > ANT <if> condition doesn't seem to work while using
> >
> > maven-antrun-plugin.
> >
> > > I have added the ant-contrib dependency.
> > >
> > > Could someone please let me know what may be the issue. Please send
> > > me
> > >
> > > a sample code if you have any.
> > >
> > > Thanks
> > > -Jagan
> >
> > --
> > Kenney Westerhof
> > http://www.neonics.com
> > GPG public key: http://www.gods.nl/~forge/kenneyw.key
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
>
> --
> J. Daniel Kulp
> dan@kulp.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message