Re: attainGoal in Ant

2006-07-24 Thread dcabasson


Michael Mekaail wrote:
> 
> Hey,
> How do I call an ant/Java plugin from within an ant/Java plugin.
> Eg. in Maven 1 i used to do
> 
> 
> What's the equivalent in Maven 2.0.4
> 

Not sure what you are trying to do...
To execute a ant target in your build use the maven-antrun-plugin:
http://maven.apache.org/plugins/maven-antrun-plugin/usage.html

Denis
-- 
View this message in context: 
http://www.nabble.com/attainGoal-in-Ant-tf1990293.html#a5463091
Sent from the Maven - Users forum at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



attainGoal in Ant

2006-07-23 Thread Michael Mekaail

Hey,
How do I call an ant/Java plugin from within an ant/Java plugin.
Eg. in Maven 1 i used to do


What's the equivalent in Maven 2.0.4

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: how to replace attainGoal in Maven 1 with plugin goal in Maven 2

2006-04-24 Thread dan tran
Hai,

It is best that you read maven book at http://www.mergere.com/products.jsp

It has a comprehensive section on building J2EE artifacts

-D


On 4/24/06, Hai Phan <[EMAIL PROTECTED]> wrote:
>
> Dear all,
> I am new to Maven 2.  I have a project that written in Maven 1 to build
> an EAR, and I would like to migrate it to Maven 2.
>
> Below is my maven.xml.  Could someone help to convert it to plugin
> (maven 2 goals) please? Just do 1 or 2 goals would be sufficient
>
> 
>  xmlns:maven="jelly:maven">
>
>
>
>basedir="${basedir}"
>includes="main/project.xml,web/project.xml,ear/project.xml"
>goals="clean"
>banner="Cleaning Targets"
>ignoreFailures="false"/>
>
>
>
>basedir="${basedir}"
>includes="main/project.xml,web/project.xml,ear/project.xml"
>goals="dist"
>banner="Building iPort2 ALL"
>ignoreFailures="false"/>
>
>
> >
>
>basedir="${basedir}"
>includes="main/project.xml"
>goals="clean,jar:install"
>banner="Building iPort2 Main"
>ignoreFailures="false"/>
>basedir="${basedir}"
>includes="web/project.xml"
>goals="clean,war:install"
>banner="Building iPort2 Web"
>ignoreFailures="false"/>
>
>basedir="${basedir}"
>includes="ear/project.xml"
>goals="clean,ear"
>banner="Building iPort2 EAR"
>ignoreFailures="false"/>
>
> 
>
> Best Regards,
> Hai Phan
>
>
>
>
>
> This communication is for informational purposes only. It is not intended
> as an offer or solicitation for the purchase or sale of any financial
> instrument or as an official confirmation of any transaction. All market
> prices,
> data and other information are not warranted as to completeness or
> accuracy and
> are subject to change without notice. Any comments or statements made
> herein
> do not necessarily reflect those of JPMorgan Chase & Co., its subsidiaries
> and affiliates.
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


how to replace attainGoal in Maven 1 with plugin goal in Maven 2

2006-04-24 Thread Hai Phan
Dear all,
I am new to Maven 2.  I have a project that written in Maven 1 to build
an EAR, and I would like to migrate it to Maven 2.

Below is my maven.xml.  Could someone help to convert it to plugin
(maven 2 goals) please? Just do 1 or 2 goals would be sufficient






















Best Regards,
Hai Phan





This communication is for informational purposes only. It is not intended
as an offer or solicitation for the purchase or sale of any financial
instrument or as an official confirmation of any transaction. All market prices,
data and other information are not warranted as to completeness or accuracy and
are subject to change without notice. Any comments or statements made herein 
do not necessarily reflect those of JPMorgan Chase & Co., its subsidiaries 
and affiliates.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



attainGoal not getting called.

2006-02-16 Thread Manisha Sur
i have goals defined in the root's maven.xml:

--





--

and the subprojects contains maven.xml as follows:

--

  

--


when i invoke 'maven' , 'petstore:build' being the default goal, on the root
, it does clean all the subprojects but twice.Moreover it doesn't execute
the petstore:build i.e. installs goal on the subprojects. Why is it so ?



--
Warm Regards
Manisha Sur


RE: attainGoal,what is it?

2006-01-18 Thread Zheng Wen Zhe
Thanks Arnaud.Very helpful.

Regards,
Jason

-Original Message-
From: Arnaud HERITIER [mailto:[EMAIL PROTECTED]
Sent: 18 January 2006 15:54
To: Maven Users List
Subject: Re: attainGoal,what is it?


It's not really documented in maven :
http://maven.apache.org/maven-1.x/tags.html#werkz:mavenAttainGoal

This tag is used to call another goal.

In your case, if you don't do anything else that to use several attainGoal
you could do :


Arnaud

On 1/18/06, Zheng Wen Zhe <[EMAIL PROTECTED]> wrote:
>
> Hi,
> what does this attainGoal do within the code below?
>
> 
> 
> 
> 
>   
> 
> Is there any article I could refer to?
>
> Thanks,
> Jason
>
> -
> 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]



Re: attainGoal,what is it?

2006-01-18 Thread Arnaud HERITIER
It's not really documented in maven :
http://maven.apache.org/maven-1.x/tags.html#werkz:mavenAttainGoal

This tag is used to call another goal.

In your case, if you don't do anything else that to use several attainGoal
you could do :


Arnaud

On 1/18/06, Zheng Wen Zhe <[EMAIL PROTECTED]> wrote:
>
> Hi,
> what does this attainGoal do within the code below?
>
> 
> 
> 
> 
>   
> 
> Is there any article I could refer to?
>
> Thanks,
> Jason
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


attainGoal,what is it?

2006-01-18 Thread Zheng Wen Zhe
Hi,
what does this attainGoal do within the code below?
 
 



  

Is there any article I could refer to?

Thanks,
Jason

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Error while executing attainGoal

2005-09-07 Thread nehalshah





Hi,

Here I am getting this error:

C:\Build_View>maven
 __  __
|  \/  |__ _Apache__ ___
| |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
|_|  |_\__,_|\_/\___|_||_|  v. 1.0.2

Starting the reactor...
Our processing order:
Web Application
+
| Building Web Application
| Memory: 6M/9M
+

BUILD FAILED
File.. C:\Build_View\maven.xml
Element... m:reactor
Line.. 8
Column 40
Unable to obtain goal [Artifact-build] -- C:\Build_View\Components\wars\
P2G_PortalWeb\maven.xml:3:36: 
org/apache/velocity/exception/Resourc
eNotFoundException
Total time: 4 seconds
Finished at: Wed Sep 07 18:12:39 IST 2005

* This is my maven.xml **

  

  

**

Please advise.

Nehal





HSBC Software Development (India) Pvt Ltd
HSBC Center, Riverside, West Avenue,
25-B Raheja Woods, Kalyani Nagar, Pune 411006.

Telephone: +91 20 26683000
Fax: +91 20 26681030



-
***
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]



RE: attainGoal

2004-04-15 Thread Sri Sankaran
It's how you call another goal from another goal (or pre/postGoal).

For example


  
 

Here if you run "maven myPlugin:myGoal", the java:compile goal will get executed.

If you have (in your maven.xml)


  


The xdoclet:webdoclet goal will be executed before java:compile is run.

Hope that helps

Sri

-Original Message-
From: Raphael Philipe Mendes da Silva [mailto:[EMAIL PROTECTED] 
Sent: Thursday, April 15, 2004 8:56 AM
To: Maven Users List (E-mail)
Subject: attainGoal

What do exactly the attainGoal tag??

I can't found some documentation about it. Someone can help me???


Raphael Philipe Mendes da Silva
DSB - Diretoria de Soluções em Billing
CPqD Telecom & IT Solutions
Tel.: +55 19 3705-6957
www.cpqd.com.br
[EMAIL PROTECTED]



-
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]



attainGoal

2004-04-15 Thread Raphael Philipe Mendes da Silva
What do exactly the attainGoal tag??

I can't found some documentation about it. Someone can help me???


Raphael Philipe Mendes da Silva
DSB - Diretoria de Soluções em Billing
CPqD Telecom & IT Solutions
Tel.: +55 19 3705-6957
www.cpqd.com.br
[EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Difference in behaviour with preGoal or attainGoal

2004-03-16 Thread Marco Tedone
Hi, I defined the following goal in my project-specific plugin:





I then defined in my project's maven.xml a simple goal:


  


If I run the following command from my project's root directory:

maven xdoclet-ejbdoclet

The ejbdoclet target defined in my plugin works fine, and the EJBs
interfaces get generated.

However, if I insert the following in my project's maven.xml:


  


I obtain the following error:

BUILD FAILED
File.. file:/C:/Documents and
Settings/mtedone/.maven/plugins/maven-jemos-plugin-1.0/
Element... maven:reactor
Line.. 405
Column 30
Unable to obtain goal [driver] -- 
file:/D:/Projects/jemos-xmlop-1.0/src/:49:50:  No goal
[jemos:xdoclet
-ejbdoclet]
Total time: 5 seconds
Finished at: Tue Mar 16 23:28:46 GMT 2004

There is obviously a difference in behaviour. It would seem that when
inserted as a preGoal, my plugin is not considered.

Could anyone help?

Marco




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



preGoal, attainGoal question

2004-01-21 Thread mruff
Hello,
I'm new to maven.
My intention is to checkout a project (scm:checkout-project) and the 
build it (site:generate)

I wanted this to achive with the following maven.xml file:


  
  

  
  
  

The problem now is the the scm:checkout-project is not exectued, and I 
do not know why. The project.xml and project.properties files are 
correct. If I call maven site:generate or maven scm:checkout-project 
individually without the maven.xml file they both work fine. But I do 
not get it to work together like I want:
1. checkout
2. site generate

Thanks for help

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Cactus problem - Difference between goal prereqs and attainGoal?

2003-12-12 Thread Sean Timm
Nevermind...it's a different issue.  The JBoss plugin's deploy-warfile
task calls war:war after I've already called it (via cactus:cactifywar),
and it was overwriting my web.xml or something...

-- Sean T.

> -Original Message-
> From: Sean Timm 
> Sent: Friday, December 12, 2003 8:42 AM
> To: [EMAIL PROTECTED]
> Subject: Cactus problem - Difference between goal prereqs and 
> attainGoal?
> 
> The cactifywar ant task (used by the Cactus plugin's 
> cactifywar task) automatically merges the redirectors into 
> the web.xml file.  I created a custom goal in a maven.xml 
> file, and I set prereqs="cactus:cactifywar".
> However, the resultant cactified war file does not contain 
> the redirectors.  However, if I remove the prereqs, and 
> instead call it via an attainGoal tag, the redirectors are 
> correctly added.
> 
> What is the difference between these two that would cause 
> this unusual behavior?
> 
> Thanks!
> 
> -- Sean T.
> 
> -
> 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]



Cactus problem - Difference between goal prereqs and attainGoal?

2003-12-12 Thread Sean Timm
The cactifywar ant task (used by the Cactus plugin's cactifywar task)
automatically merges the redirectors into the web.xml file.  I created a
custom goal in a maven.xml file, and I set prereqs="cactus:cactifywar".
However, the resultant cactified war file does not contain the
redirectors.  However, if I remove the prereqs, and instead call it via
an attainGoal tag, the redirectors are correctly added.

What is the difference between these two that would cause this unusual
behavior?

Thanks!

-- Sean T.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: AttainGoal question

2003-12-11 Thread Jefferson K. French
Is this also the reason the console plugin fails when it tries to run
a multiproject:goal a second time?

On Thu, 11 Dec 2003, at 09:28:28 [GMT +1100] Peter Donald wrote:

> On Thu, 11 Dec 2003 03:10 am, Lester Ward wrote:
>> Can anyone tell me what the difference is between running a goal from the
>> command line vs. having that goal called by an  tag? Over the
>> last few days, I've seen three problems where I could run a goal just fine
>> from a command line, but if the same goal was invoked from an 
>> tag, various strange errors occur.
>>
>> Makes it very hard to track down the problem. I assume there is some sort
>> of differnce between the way the goal is invoked that is the culprit.

> AtainGoal starts a new session so if you do an attainGoal on a goal already 
> completed it will be reprocessed BUT pregoals and postgoals will not be 
> re-executed. Major PITA :)


-- 
mailto:[EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: AttainGoal question

2003-12-10 Thread Peter Donald
On Thu, 11 Dec 2003 03:10 am, Lester Ward wrote:
> Can anyone tell me what the difference is between running a goal from the
> command line vs. having that goal called by an  tag? Over the
> last few days, I've seen three problems where I could run a goal just fine
> from a command line, but if the same goal was invoked from an 
> tag, various strange errors occur.
>
> Makes it very hard to track down the problem. I assume there is some sort
> of differnce between the way the goal is invoked that is the culprit.

AtainGoal starts a new session so if you do an attainGoal on a goal already 
completed it will be reprocessed BUT pregoals and postgoals will not be 
re-executed. Major PITA :)

-- 
Cheers,

Peter Donald
"Never interrupt your enemy when he is making 
a mistake." - Napoleon Bonaparte (1769-1821) 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: AttainGoal question

2003-12-10 Thread Jason van Zyl
On Wed, 2003-12-10 at 11:56, Lester Ward wrote:
> > Currently  doesn't share the same session in 
> > which the rest of the goals are attained.
> 
> How might this session be different? Does it use a different classpath? Load
> plugins differently?

It's the werkz session which keeps track of which goals have been
attainted and those that have not. I would have to take a look if there
is anything different other than that.

> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
-- 
jvz.

Jason van Zyl
[EMAIL PROTECTED]
http://tambora.zenplex.org

In short, man creates for himself a new religion of a rational
and technical order to justify his work and to be justified in it.
  
  -- Jacques Ellul, The Technological Society


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: AttainGoal question

2003-12-10 Thread Lester Ward
> Currently  doesn't share the same session in 
> which the rest of the goals are attained.

How might this session be different? Does it use a different classpath? Load
plugins differently?

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: AttainGoal question

2003-12-10 Thread Jason van Zyl
On Wed, 2003-12-10 at 11:10, Lester Ward wrote:
> Can anyone tell me what the difference is between running a goal from the
> command line vs. having that goal called by an  tag? Over the
> last few days, I've seen three problems where I could run a goal just fine
> from a command line, but if the same goal was invoked from an 
> tag, various strange errors occur.

 creates a new werkz session which is mostly likely the
cause of the strange behaviour you are seeing.

> Makes it very hard to track down the problem. I assume there is some sort of
> differnce between the way the goal is invoked that is the culprit.

Currently  doesn't share the same session in which the rest
of the goals are attained.

> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
-- 
jvz.

Jason van Zyl
[EMAIL PROTECTED]
http://tambora.zenplex.org

In short, man creates for himself a new religion of a rational
and technical order to justify his work and to be justified in it.
  
  -- Jacques Ellul, The Technological Society


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



AttainGoal question

2003-12-10 Thread Lester Ward
Can anyone tell me what the difference is between running a goal from the
command line vs. having that goal called by an  tag? Over the
last few days, I've seen three problems where I could run a goal just fine
from a command line, but if the same goal was invoked from an 
tag, various strange errors occur.

Makes it very hard to track down the problem. I assume there is some sort of
differnce between the way the goal is invoked that is the culprit.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



attainGoal and maven:reactor

2003-10-31 Thread Eric Chow
Hello,

Would you please to tell me when what's the difference between attainGoal
and maven:reactor ?

Both of them are used for calling another Goal !!!

When should use "attainGoal" and when should use "maven:reactor" ???

Eric


==
If you know what you are doing,
it is not called RESEARCH!
==


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Maven API: Project object and attainGoal

2003-10-06 Thread Jason van Zyl
On Sun, 2003-10-05 at 21:22, Jean-Noel Filippi wrote:
> Hi there,
> 
> After instanciating a maven Project object, how can I attain a goal (like
> java:compile)?
> 
> I tried to add a goal with a MavenSession object and run 'attaingoal'
> but it does not work. Here is my code:
> Project p = MavenUtils.getProject("project.xml");
> p.initialize();
> MavenSession mavenSession = new MavenSession();
> mavenSession.setRootProject(p);
> mavenSession.addGoalName("java:compile");
> mavenSession.attainGoals();
> 
> Thank you for your help !

The current incarnation of Maven is not very bean-like. Brett has been
working on merging some changes that I made to enable Maven to work in a
more bean like way but what is present now does not make embedding easy.

I assume you are trying to embed Maven?

> Jn
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
-- 
jvz.

Jason van Zyl
[EMAIL PROTECTED]
http://tambora.zenplex.org

In short, man creates for himself a new religion of a rational
and technical order to justify his work and to be justified in it.
  
  -- Jacques Ellul, The Technological Society


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Maven API: Project object and attainGoal

2003-10-05 Thread Jean-Noel Filippi
Hi there,

After instanciating a maven Project object, how can I attain a goal (like
java:compile)?

I tried to add a goal with a MavenSession object and run 'attaingoal'
but it does not work. Here is my code:
Project p = MavenUtils.getProject("project.xml");
p.initialize();
MavenSession mavenSession = new MavenSession();
mavenSession.setRootProject(p);
mavenSession.addGoalName("java:compile");
mavenSession.attainGoals();

Thank you for your help !

Jn

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



attainGoal and JellyContext

2003-06-23 Thread Rademacher Tobias
Hi Folks,

whenever I attain a goal from a different plugin the current JellyContext is
not submitted. Does attainGoal offering the ability to submit the current
JellyContext? If yes: How?

Thx 

Toby

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]