You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by "Petr V." <gr...@yahoo.com> on 2008/10/30 18:37:49 UTC

Nant Plugin for Maven to integrate dot net component in main project build ?

I have a project that has many components. Some are written in dot net and some are in java.We are moving our build environment to maven.

I can call ant scripts from maven but I am wondering if it is possible to call nant scripts from maven. Nant scripts are used to build dot net project. Is it possible to call nant scripts from my main project pom file ? 

What would be the most efficient way to do that ? I do not want to touch the nant scripts that haven been working fine to quite long time.

Any pointer would be really appreciated ?

Thanks,

Petr



      

Re: Nant Plugin for Maven to integrate dot net component in main project build ?

Posted by Wendy Smoak <ws...@gmail.com>.
...and if you do that, then consider contributing it to NMaven.
Another user has already requested it:
http://jira.codehaus.org/browse/NMAVEN-225

-- 
Wendy

On Thu, Oct 30, 2008 at 2:20 PM, Wayne Fay <wa...@gmail.com> wrote:
> And if you don't like exec-m-p, just write your own nant-m-p. Plugins
> are surprisingly simply to write.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Nant Plugin for Maven to integrate dot net component in main project build ?

Posted by Wayne Fay <wa...@gmail.com>.
And if you don't like exec-m-p, just write your own nant-m-p. Plugins
are surprisingly simply to write.

Wayne

On Thu, Oct 30, 2008 at 2:13 PM, Stephen Connolly
<st...@gmail.com> wrote:
> have a look at the exec-maven-plugin

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: exec-maven-plugin exit Code Issue

Posted by Stephen Connolly <st...@gmail.com>.
if you're running ant you'd be better off with maven-antrun-plugin

I thought you were running nant

2008/10/31 Petr V. <gr...@yahoo.com>

> Okay here is some more update. I called the simple bat file returning 0 and
> 1 via exec-maven-plugin and then maven build failed/passed accordingly.
>
> So it means that ant script is not returning proper error code to
> exec-maven-plugin So next question arises that can we force ant to return
> error code when ant script fails :-)
>
> Thanks,
>
> Petr
>
> --- On Fri, 10/31/08, Petr V. <gr...@yahoo.com> wrote:
> From: Petr V. <gr...@yahoo.com>
> Subject: exec-maven-plugin exit Code Issue
> To: "Maven Users List" <us...@maven.apache.org>
> Date: Friday, October 31, 2008, 10:58 PM
>
> Okay as advised by Stephen  Connolly, from my maven pom file , I am trying
> to
> call some other script(let's
> assume it is an ant script for sake of discussion) which fails but my
> maven build process goes on. I want my maven build to fail if it calls
> some external script which fails. I looked at documentation of plugin
> but I don't see any option that would help me setting up what to do when
> my called program or script via exec-maven-plugin fails
>
>
>
>   <plugin>
>
>         <groupId>org.codehaus.mojo</groupId>
>
>         <artifactId>exec-maven-plugin</artifactId>
>
>         <version>1.1</version>
>
>         <executions>
>
>           <execution>
>
>             <id>dowithant</id>
>
>             <configuration>
>
>               <executable>ant</executable>
>
>             </configuration>
>
>               <phase>compile</phase>
>
>             <goals>
>
>               <goal>exec</goal>
>
>             </goals>
>
>           </execution>
>
>         </executions>
>
>  </plugin>
>
>
>
> It calls my ant script which fails but it goes on with my maven build :-(.
>
>
>
> Is there any way I can catch the failure of external script ?
>
>
>
> Thanks,
>
>
>
> Petr
>
>
> --- On Fri, 10/31/08, Stephen Connolly <st...@gmail.com>
> wrote:
> From: Stephen Connolly <st...@gmail.com>
> Subject: Re: Nant Plugin for Maven to integrate dot net component in main
> project build ?
> To: "Maven Users List" <us...@maven.apache.org>,
> greatman787@yahoo.com
> Date: Friday, October 31, 2008, 2:13 AM
>
> have a look at the exec-maven-plugin
>
> 2008/10/30 Petr V. <gr...@yahoo.com>
>
> > Yeah we have looked into nMaven but these are the existing projects and
> we
> > do not want to put effort to convert them to nMaven _now_.
> >
> > Is there any way possible to call nant script from maven ?
> >
> > Thanks,
> >
> > Petr
> >
> >
> >
> >
> >
> > --- On Thu, 10/30/08, Wayne Fay <wa...@gmail.com> wrote:
> > From: Wayne Fay <wa...@gmail.com>
> > Subject: Re: Nant Plugin for Maven to integrate dot net component in main
> > project build ?
> > To: "Maven Users List" <us...@maven.apache.org>
> > Date: Thursday, October 30, 2008, 11:47 PM
> >
> > On Thu, Oct 30, 2008 at 10:37 AM, Petr V. <gr...@yahoo.com>
> wrote:
> > > I have a project that has many components. Some are written in dot
> net
> > and
> > some are in java.We are moving our build environment to maven.
> >
> > I'd encourage you to look at NMaven:
> > http://incubator.apache.org/nmaven/
> >
> > I don't use it myself, but I know others are using it successfully
> > with their dot-net projects.
> >
> > Wayne
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
> >
> >
> >
> >
> >
> >
>
>
>
>
>
>
>
>

Re: exec-maven-plugin exit Code Issue

Posted by "Petr V." <gr...@yahoo.com>.
Okay here is some more update. I called the simple bat file returning 0 and 1 via exec-maven-plugin and then maven build failed/passed accordingly.

So it means that ant script is not returning proper error code to exec-maven-plugin So next question arises that can we force ant to return error code when ant script fails :-)

Thanks,

Petr

--- On Fri, 10/31/08, Petr V. <gr...@yahoo.com> wrote:
From: Petr V. <gr...@yahoo.com>
Subject: exec-maven-plugin exit Code Issue
To: "Maven Users List" <us...@maven.apache.org>
Date: Friday, October 31, 2008, 10:58 PM

Okay as advised by Stephen  Connolly, from my maven pom file , I am trying to
call some other script(let's
assume it is an ant script for sake of discussion) which fails but my
maven build process goes on. I want my maven build to fail if it calls
some external script which fails. I looked at documentation of plugin
but I don't see any option that would help me setting up what to do when
my called program or script via exec-maven-plugin fails



  <plugin>

        <groupId>org.codehaus.mojo</groupId>

        <artifactId>exec-maven-plugin</artifactId>

        <version>1.1</version>

        <executions>

          <execution>

            <id>dowithant</id>

            <configuration>

              <executable>ant</executable>

            </configuration>

              <phase>compile</phase>

            <goals>

              <goal>exec</goal>

            </goals>

          </execution>         

        </executions>

 </plugin>



It calls my ant script which fails but it goes on with my maven build :-(.



Is there any way I can catch the failure of external script ?



Thanks,



Petr


--- On Fri, 10/31/08, Stephen Connolly <st...@gmail.com>
wrote:
From: Stephen Connolly <st...@gmail.com>
Subject: Re: Nant Plugin for Maven to integrate dot net component in main
project build ?
To: "Maven Users List" <us...@maven.apache.org>,
greatman787@yahoo.com
Date: Friday, October 31, 2008, 2:13 AM

have a look at the exec-maven-plugin

2008/10/30 Petr V. <gr...@yahoo.com>

> Yeah we have looked into nMaven but these are the existing projects and we
> do not want to put effort to convert them to nMaven _now_.
>
> Is there any way possible to call nant script from maven ?
>
> Thanks,
>
> Petr
>
>
>
>
>
> --- On Thu, 10/30/08, Wayne Fay <wa...@gmail.com> wrote:
> From: Wayne Fay <wa...@gmail.com>
> Subject: Re: Nant Plugin for Maven to integrate dot net component in main
> project build ?
> To: "Maven Users List" <us...@maven.apache.org>
> Date: Thursday, October 30, 2008, 11:47 PM
>
> On Thu, Oct 30, 2008 at 10:37 AM, Petr V. <gr...@yahoo.com>
wrote:
> > I have a project that has many components. Some are written in dot
net
> and
> some are in java.We are moving our build environment to maven.
>
> I'd encourage you to look at NMaven:
> http://incubator.apache.org/nmaven/
>
> I don't use it myself, but I know others are using it successfully
> with their dot-net projects.
>
> Wayne
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
>
>
>
>



      


      

Re: exec-maven-plugin exit Code Issue

Posted by "Petr V." <gr...@yahoo.com>.
Worked like a charm. BIG THANK YOU Stephen. 

--- On Sat, 11/1/08, Stephen Connolly <st...@gmail.com> wrote:
From: Stephen Connolly <st...@gmail.com>
Subject: Re: exec-maven-plugin exit Code Issue
To: "Maven Users List" <us...@maven.apache.org>
Cc: "Maven Users List" <us...@maven.apache.org>
Date: Saturday, November 1, 2008, 4:11 AM

add inherited false to the plugin section

Sent from my iPod

On 31 Oct 2008, at 23:10, "Petr V." <gr...@yahoo.com>
wrote:

> It's going to be a fun week end :-(
>
> Okay so here is some more update . The nant script is call as many  
> times as pom files I have in whole project ... I added the exec  
> plugin definition in top pom file but it is executed for each sub  
> module .... How could I stop it from doing it ?
>
> Any help will make my Halloween evening cool  :-)
>
> Thanks,
>
> Petr
>
> --- On Sat, 11/1/08, Petr V. <gr...@yahoo.com> wrote:
> From: Petr V. <gr...@yahoo.com>
> Subject: Re: exec-maven-plugin exit Code Issue
> To: "Maven Users List" <us...@maven.apache.org>
> Date: Saturday, November 1, 2008, 3:51 AM
>
> I am able to call my nant buid via exec-maven-plugin but my nnat  
> script is keep
> callin agian and again and build process never ends.
>
> I put the following in my top pom file of project. I guess phase  
> mean when we
> need to call the nant script iof folliwng snippet but what does
> <goal>exec</goal> mean ?
>
> <plugin>
>
> <groupId>org.codehaus.mojo</groupId>
>
> <artifactId>exec-maven-plugin</artifactId>
>                     <version>1.1</version>
>                     <executions>
>                       <execution>
>                         <id>nantbuild</id>
>                         <configuration>
>
> <executable>nant</executable>
>
> <workingDirectory>F:\shared</workingDirectory>
>                         </configuration>
>
> <phase>compile</phase>
>                         <goals>
>
> <goal>exec</goal>
>                         </goals>
>                       </execution>
>                     </executions>
> </plugin>
>
> Thanks,
>
> Petr
>
> --- On Fri, 10/31/08, Petr V. <gr...@yahoo.com> wrote:
> From: Petr V. <gr...@yahoo.com>
> Subject: exec-maven-plugin exit Code Issue
> To: "Maven Users List" <us...@maven.apache.org>
> Date: Friday, October 31, 2008, 10:58 PM
>
> Okay as advised by Stephen  Connolly, from my maven pom file , I am  
> trying to
> call some other script(let's
> assume it is an ant script for sake of discussion) which fails but my
> maven build process goes on. I want my maven build to fail if it calls
> some external script which fails. I looked at documentation of plugin
> but I don't see any option that would help me setting up what to do  
> when
> my called program or script via exec-maven-plugin fails
>
>
>
>   <plugin>
>
>         <groupId>org.codehaus.mojo</groupId>
>
>         <artifactId>exec-maven-plugin</artifactId>
>
>         <version>1.1</version>
>
>         <executions>
>
>           <execution>
>
>             <id>dowithant</id>
>
>             <configuration>
>
>               <executable>ant</executable>
>
>             </configuration>
>
>               <phase>compile</phase>
>
>             <goals>
>
>               <goal>exec</goal>
>
>             </goals>
>
>           </execution>
>
>         </executions>
>
>  </plugin>
>
>
>
> It calls my ant script which fails but it goes on with my maven  
> build :-(.
>
>
>
> Is there any way I can catch the failure of external script ?
>
>
>
> Thanks,
>
>
>
> Petr
>
>
> --- On Fri, 10/31/08, Stephen Connolly <stephen.alan.connolly@gmail.com

> >
> wrote:
> From: Stephen Connolly <st...@gmail.com>
> Subject: Re: Nant Plugin for Maven to integrate dot net component in  
> main
> project build ?
> To: "Maven Users List" <us...@maven.apache.org>,
> greatman787@yahoo.com
> Date: Friday, October 31, 2008, 2:13 AM
>
> have a look at the exec-maven-plugin
>
> 2008/10/30 Petr V. <gr...@yahoo.com>
>
>> Yeah we have looked into nMaven but these are the existing projects  
>> and we
>> do not want to put effort to convert them to nMaven _now_.
>>
>> Is there any way possible to call nant script from maven ?
>>
>> Thanks,
>>
>> Petr
>>
>>
>>
>>
>>
>> --- On Thu, 10/30/08, Wayne Fay <wa...@gmail.com> wrote:
>> From: Wayne Fay <wa...@gmail.com>
>> Subject: Re: Nant Plugin for Maven to integrate dot net component  
>> in main
>> project build ?
>> To: "Maven Users List" <us...@maven.apache.org>
>> Date: Thursday, October 30, 2008, 11:47 PM
>>
>> On Thu, Oct 30, 2008 at 10:37 AM, Petr V.
<gr...@yahoo.com>
> wrote:
>>> I have a project that has many components. Some are written in dot
> net
>> and
>> some are in java.We are moving our build environment to maven.
>>
>> I'd encourage you to look at NMaven:
>> http://incubator.apache.org/nmaven/
>>
>> I don't use it myself, but I know others are using it successfully
>> with their dot-net projects.
>>
>> Wayne
>>
>> ---------------------------------------------------------------------
>> 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




      

Re: exec-maven-plugin exit Code Issue

Posted by Stephen Connolly <st...@gmail.com>.
add inherited false to the plugin section

Sent from my iPod

On 31 Oct 2008, at 23:10, "Petr V." <gr...@yahoo.com> wrote:

> It's going to be a fun week end :-(
>
> Okay so here is some more update . The nant script is call as many  
> times as pom files I have in whole project ... I added the exec  
> plugin definition in top pom file but it is executed for each sub  
> module .... How could I stop it from doing it ?
>
> Any help will make my Halloween evening cool  :-)
>
> Thanks,
>
> Petr
>
> --- On Sat, 11/1/08, Petr V. <gr...@yahoo.com> wrote:
> From: Petr V. <gr...@yahoo.com>
> Subject: Re: exec-maven-plugin exit Code Issue
> To: "Maven Users List" <us...@maven.apache.org>
> Date: Saturday, November 1, 2008, 3:51 AM
>
> I am able to call my nant buid via exec-maven-plugin but my nnat  
> script is keep
> callin agian and again and build process never ends.
>
> I put the following in my top pom file of project. I guess phase  
> mean when we
> need to call the nant script iof folliwng snippet but what does
> <goal>exec</goal> mean ?
>
> <plugin>
>
> <groupId>org.codehaus.mojo</groupId>
>
> <artifactId>exec-maven-plugin</artifactId>
>                     <version>1.1</version>
>                     <executions>
>                       <execution>
>                         <id>nantbuild</id>
>                         <configuration>
>
> <executable>nant</executable>
>
> <workingDirectory>F:\shared</workingDirectory>
>                         </configuration>
>
> <phase>compile</phase>
>                         <goals>
>
> <goal>exec</goal>
>                         </goals>
>                       </execution>
>                     </executions>
> </plugin>
>
> Thanks,
>
> Petr
>
> --- On Fri, 10/31/08, Petr V. <gr...@yahoo.com> wrote:
> From: Petr V. <gr...@yahoo.com>
> Subject: exec-maven-plugin exit Code Issue
> To: "Maven Users List" <us...@maven.apache.org>
> Date: Friday, October 31, 2008, 10:58 PM
>
> Okay as advised by Stephen  Connolly, from my maven pom file , I am  
> trying to
> call some other script(let's
> assume it is an ant script for sake of discussion) which fails but my
> maven build process goes on. I want my maven build to fail if it calls
> some external script which fails. I looked at documentation of plugin
> but I don't see any option that would help me setting up what to do  
> when
> my called program or script via exec-maven-plugin fails
>
>
>
>   <plugin>
>
>         <groupId>org.codehaus.mojo</groupId>
>
>         <artifactId>exec-maven-plugin</artifactId>
>
>         <version>1.1</version>
>
>         <executions>
>
>           <execution>
>
>             <id>dowithant</id>
>
>             <configuration>
>
>               <executable>ant</executable>
>
>             </configuration>
>
>               <phase>compile</phase>
>
>             <goals>
>
>               <goal>exec</goal>
>
>             </goals>
>
>           </execution>
>
>         </executions>
>
>  </plugin>
>
>
>
> It calls my ant script which fails but it goes on with my maven  
> build :-(.
>
>
>
> Is there any way I can catch the failure of external script ?
>
>
>
> Thanks,
>
>
>
> Petr
>
>
> --- On Fri, 10/31/08, Stephen Connolly <stephen.alan.connolly@gmail.com 
> >
> wrote:
> From: Stephen Connolly <st...@gmail.com>
> Subject: Re: Nant Plugin for Maven to integrate dot net component in  
> main
> project build ?
> To: "Maven Users List" <us...@maven.apache.org>,
> greatman787@yahoo.com
> Date: Friday, October 31, 2008, 2:13 AM
>
> have a look at the exec-maven-plugin
>
> 2008/10/30 Petr V. <gr...@yahoo.com>
>
>> Yeah we have looked into nMaven but these are the existing projects  
>> and we
>> do not want to put effort to convert them to nMaven _now_.
>>
>> Is there any way possible to call nant script from maven ?
>>
>> Thanks,
>>
>> Petr
>>
>>
>>
>>
>>
>> --- On Thu, 10/30/08, Wayne Fay <wa...@gmail.com> wrote:
>> From: Wayne Fay <wa...@gmail.com>
>> Subject: Re: Nant Plugin for Maven to integrate dot net component  
>> in main
>> project build ?
>> To: "Maven Users List" <us...@maven.apache.org>
>> Date: Thursday, October 30, 2008, 11:47 PM
>>
>> On Thu, Oct 30, 2008 at 10:37 AM, Petr V. <gr...@yahoo.com>
> wrote:
>>> I have a project that has many components. Some are written in dot
> net
>> and
>> some are in java.We are moving our build environment to maven.
>>
>> I'd encourage you to look at NMaven:
>> http://incubator.apache.org/nmaven/
>>
>> I don't use it myself, but I know others are using it successfully
>> with their dot-net projects.
>>
>> Wayne
>>
>> ---------------------------------------------------------------------
>> 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


Re: exec-maven-plugin exit Code Issue

Posted by "Petr V." <gr...@yahoo.com>.
It's going to be a fun week end :-(

Okay so here is some more update . The nant script is call as many times as pom files I have in whole project ... I added the exec plugin definition in top pom file but it is executed for each sub module .... How could I stop it from doing it ?

Any help will make my Halloween evening cool  :-)

Thanks,

Petr 

--- On Sat, 11/1/08, Petr V. <gr...@yahoo.com> wrote:
From: Petr V. <gr...@yahoo.com>
Subject: Re: exec-maven-plugin exit Code Issue
To: "Maven Users List" <us...@maven.apache.org>
Date: Saturday, November 1, 2008, 3:51 AM

I am able to call my nant buid via exec-maven-plugin but my nnat script is keep
callin agian and again and build process never ends.

I put the following in my top pom file of project. I guess phase mean when we
need to call the nant script iof folliwng snippet but what does
<goal>exec</goal> mean ? 

<plugin>
                   
<groupId>org.codehaus.mojo</groupId>
                   
<artifactId>exec-maven-plugin</artifactId>
                    <version>1.1</version>
                    <executions>
                      <execution>
                        <id>nantbuild</id>
                        <configuration>
                         
<executable>nant</executable>
                          
<workingDirectory>F:\shared</workingDirectory>
                        </configuration>
                         
<phase>compile</phase>
                        <goals>
                         
<goal>exec</goal>
                        </goals>
                      </execution>         
                    </executions>
</plugin>           

Thanks,

Petr

--- On Fri, 10/31/08, Petr V. <gr...@yahoo.com> wrote:
From: Petr V. <gr...@yahoo.com>
Subject: exec-maven-plugin exit Code Issue
To: "Maven Users List" <us...@maven.apache.org>
Date: Friday, October 31, 2008, 10:58 PM

Okay as advised by Stephen  Connolly, from my maven pom file , I am trying to
call some other script(let's
assume it is an ant script for sake of discussion) which fails but my
maven build process goes on. I want my maven build to fail if it calls
some external script which fails. I looked at documentation of plugin
but I don't see any option that would help me setting up what to do when
my called program or script via exec-maven-plugin fails



  <plugin>

        <groupId>org.codehaus.mojo</groupId>

        <artifactId>exec-maven-plugin</artifactId>

        <version>1.1</version>

        <executions>

          <execution>

            <id>dowithant</id>

            <configuration>

              <executable>ant</executable>

            </configuration>

              <phase>compile</phase>

            <goals>

              <goal>exec</goal>

            </goals>

          </execution>         

        </executions>

 </plugin>



It calls my ant script which fails but it goes on with my maven build :-(.



Is there any way I can catch the failure of external script ?



Thanks,



Petr


--- On Fri, 10/31/08, Stephen Connolly <st...@gmail.com>
wrote:
From: Stephen Connolly <st...@gmail.com>
Subject: Re: Nant Plugin for Maven to integrate dot net component in main
project build ?
To: "Maven Users List" <us...@maven.apache.org>,
greatman787@yahoo.com
Date: Friday, October 31, 2008, 2:13 AM

have a look at the exec-maven-plugin

2008/10/30 Petr V. <gr...@yahoo.com>

> Yeah we have looked into nMaven but these are the existing projects and we
> do not want to put effort to convert them to nMaven _now_.
>
> Is there any way possible to call nant script from maven ?
>
> Thanks,
>
> Petr
>
>
>
>
>
> --- On Thu, 10/30/08, Wayne Fay <wa...@gmail.com> wrote:
> From: Wayne Fay <wa...@gmail.com>
> Subject: Re: Nant Plugin for Maven to integrate dot net component in main
> project build ?
> To: "Maven Users List" <us...@maven.apache.org>
> Date: Thursday, October 30, 2008, 11:47 PM
>
> On Thu, Oct 30, 2008 at 10:37 AM, Petr V. <gr...@yahoo.com>
wrote:
> > I have a project that has many components. Some are written in dot
net
> and
> some are in java.We are moving our build environment to maven.
>
> I'd encourage you to look at NMaven:
> http://incubator.apache.org/nmaven/
>
> I don't use it myself, but I know others are using it successfully
> with their dot-net projects.
>
> Wayne
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
>
>
>
>



      


      


      

Re: exec-maven-plugin exit Code Issue

Posted by "Petr V." <gr...@yahoo.com>.
I am able to call my nant buid via exec-maven-plugin but my nnat script is keep callin agian and again and build process never ends.

I put the following in my top pom file of project. I guess phase mean when we need to call the nant script iof folliwng snippet but what does <goal>exec</goal> mean ? 

<plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>exec-maven-plugin</artifactId>
                    <version>1.1</version>
                    <executions>
                      <execution>
                        <id>nantbuild</id>
                        <configuration>
                          <executable>nant</executable>
                           <workingDirectory>F:\shared</workingDirectory>
                        </configuration>
                          <phase>compile</phase>
                        <goals>
                          <goal>exec</goal>
                        </goals>
                      </execution>         
                    </executions>
</plugin>           

Thanks,

Petr

--- On Fri, 10/31/08, Petr V. <gr...@yahoo.com> wrote:
From: Petr V. <gr...@yahoo.com>
Subject: exec-maven-plugin exit Code Issue
To: "Maven Users List" <us...@maven.apache.org>
Date: Friday, October 31, 2008, 10:58 PM

Okay as advised by Stephen  Connolly, from my maven pom file , I am trying to
call some other script(let's
assume it is an ant script for sake of discussion) which fails but my
maven build process goes on. I want my maven build to fail if it calls
some external script which fails. I looked at documentation of plugin
but I don't see any option that would help me setting up what to do when
my called program or script via exec-maven-plugin fails



  <plugin>

        <groupId>org.codehaus.mojo</groupId>

        <artifactId>exec-maven-plugin</artifactId>

        <version>1.1</version>

        <executions>

          <execution>

            <id>dowithant</id>

            <configuration>

              <executable>ant</executable>

            </configuration>

              <phase>compile</phase>

            <goals>

              <goal>exec</goal>

            </goals>

          </execution>         

        </executions>

 </plugin>



It calls my ant script which fails but it goes on with my maven build :-(.



Is there any way I can catch the failure of external script ?



Thanks,



Petr


--- On Fri, 10/31/08, Stephen Connolly <st...@gmail.com>
wrote:
From: Stephen Connolly <st...@gmail.com>
Subject: Re: Nant Plugin for Maven to integrate dot net component in main
project build ?
To: "Maven Users List" <us...@maven.apache.org>,
greatman787@yahoo.com
Date: Friday, October 31, 2008, 2:13 AM

have a look at the exec-maven-plugin

2008/10/30 Petr V. <gr...@yahoo.com>

> Yeah we have looked into nMaven but these are the existing projects and we
> do not want to put effort to convert them to nMaven _now_.
>
> Is there any way possible to call nant script from maven ?
>
> Thanks,
>
> Petr
>
>
>
>
>
> --- On Thu, 10/30/08, Wayne Fay <wa...@gmail.com> wrote:
> From: Wayne Fay <wa...@gmail.com>
> Subject: Re: Nant Plugin for Maven to integrate dot net component in main
> project build ?
> To: "Maven Users List" <us...@maven.apache.org>
> Date: Thursday, October 30, 2008, 11:47 PM
>
> On Thu, Oct 30, 2008 at 10:37 AM, Petr V. <gr...@yahoo.com>
wrote:
> > I have a project that has many components. Some are written in dot
net
> and
> some are in java.We are moving our build environment to maven.
>
> I'd encourage you to look at NMaven:
> http://incubator.apache.org/nmaven/
>
> I don't use it myself, but I know others are using it successfully
> with their dot-net projects.
>
> Wayne
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
>
>
>
>



      


      

exec-maven-plugin exit Code Issue

Posted by "Petr V." <gr...@yahoo.com>.
Okay as advised by Stephen  Connolly, from my maven pom file , I am trying to call some other script(let's
assume it is an ant script for sake of discussion) which fails but my
maven build process goes on. I want my maven build to fail if it calls
some external script which fails. I looked at documentation of plugin
but I don't see any option that would help me setting up what to do when
my called program or script via exec-maven-plugin fails



  <plugin>

        <groupId>org.codehaus.mojo</groupId>

        <artifactId>exec-maven-plugin</artifactId>

        <version>1.1</version>

        <executions>

          <execution>

            <id>dowithant</id>

            <configuration>

              <executable>ant</executable>

            </configuration>

              <phase>compile</phase>

            <goals>

              <goal>exec</goal>

            </goals>

          </execution>         

        </executions>

 </plugin>



It calls my ant script which fails but it goes on with my maven build :-(.



Is there any way I can catch the failure of external script ?



Thanks,



Petr


--- On Fri, 10/31/08, Stephen Connolly <st...@gmail.com> wrote:
From: Stephen Connolly <st...@gmail.com>
Subject: Re: Nant Plugin for Maven to integrate dot net component in main project build ?
To: "Maven Users List" <us...@maven.apache.org>, greatman787@yahoo.com
Date: Friday, October 31, 2008, 2:13 AM

have a look at the exec-maven-plugin

2008/10/30 Petr V. <gr...@yahoo.com>

> Yeah we have looked into nMaven but these are the existing projects and we
> do not want to put effort to convert them to nMaven _now_.
>
> Is there any way possible to call nant script from maven ?
>
> Thanks,
>
> Petr
>
>
>
>
>
> --- On Thu, 10/30/08, Wayne Fay <wa...@gmail.com> wrote:
> From: Wayne Fay <wa...@gmail.com>
> Subject: Re: Nant Plugin for Maven to integrate dot net component in main
> project build ?
> To: "Maven Users List" <us...@maven.apache.org>
> Date: Thursday, October 30, 2008, 11:47 PM
>
> On Thu, Oct 30, 2008 at 10:37 AM, Petr V. <gr...@yahoo.com>
wrote:
> > I have a project that has many components. Some are written in dot
net
> and
> some are in java.We are moving our build environment to maven.
>
> I'd encourage you to look at NMaven:
> http://incubator.apache.org/nmaven/
>
> I don't use it myself, but I know others are using it successfully
> with their dot-net projects.
>
> Wayne
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
>
>
>
>



      

Re: Nant Plugin for Maven to integrate dot net component in main project build ?

Posted by Stephen Connolly <st...@gmail.com>.
have a look at the exec-maven-plugin

2008/10/30 Petr V. <gr...@yahoo.com>

> Yeah we have looked into nMaven but these are the existing projects and we
> do not want to put effort to convert them to nMaven _now_.
>
> Is there any way possible to call nant script from maven ?
>
> Thanks,
>
> Petr
>
>
>
>
>
> --- On Thu, 10/30/08, Wayne Fay <wa...@gmail.com> wrote:
> From: Wayne Fay <wa...@gmail.com>
> Subject: Re: Nant Plugin for Maven to integrate dot net component in main
> project build ?
> To: "Maven Users List" <us...@maven.apache.org>
> Date: Thursday, October 30, 2008, 11:47 PM
>
> On Thu, Oct 30, 2008 at 10:37 AM, Petr V. <gr...@yahoo.com> wrote:
> > I have a project that has many components. Some are written in dot net
> and
> some are in java.We are moving our build environment to maven.
>
> I'd encourage you to look at NMaven:
> http://incubator.apache.org/nmaven/
>
> I don't use it myself, but I know others are using it successfully
> with their dot-net projects.
>
> Wayne
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
>
>
>
>

Re: Nant Plugin for Maven to integrate dot net component in main project build ?

Posted by "Petr V." <gr...@yahoo.com>.
Yeah we have looked into nMaven but these are the existing projects and we do not want to put effort to convert them to nMaven _now_.

Is there any way possible to call nant script from maven ?

Thanks,

Petr





--- On Thu, 10/30/08, Wayne Fay <wa...@gmail.com> wrote:
From: Wayne Fay <wa...@gmail.com>
Subject: Re: Nant Plugin for Maven to integrate dot net component in main project build ?
To: "Maven Users List" <us...@maven.apache.org>
Date: Thursday, October 30, 2008, 11:47 PM

On Thu, Oct 30, 2008 at 10:37 AM, Petr V. <gr...@yahoo.com> wrote:
> I have a project that has many components. Some are written in dot net and
some are in java.We are moving our build environment to maven.

I'd encourage you to look at NMaven:
http://incubator.apache.org/nmaven/

I don't use it myself, but I know others are using it successfully
with their dot-net projects.

Wayne

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org




      

Re: Nant Plugin for Maven to integrate dot net component in main project build ?

Posted by Wayne Fay <wa...@gmail.com>.
On Thu, Oct 30, 2008 at 10:37 AM, Petr V. <gr...@yahoo.com> wrote:
> I have a project that has many components. Some are written in dot net and some are in java.We are moving our build environment to maven.

I'd encourage you to look at NMaven:
http://incubator.apache.org/nmaven/

I don't use it myself, but I know others are using it successfully
with their dot-net projects.

Wayne

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org