You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Shelli Orton <Sh...@sjrb.ca> on 2010/05/05 17:13:54 UTC

Missing archetype.xml in new archetype created from project

Hi,

I am using Maven 2.2.1. and am new to Maven. I am trying to create an
archetype based on an existing project. I have been using this blog post
as a guide: http://blog.inflinx.com/category/m2eclipse/

Step 7 says "The next step is to verify that the generated archetype.xml
(located under srcmainresourcesMETA-INFmaven (sic)) has all the files
listed and they are located in the right directories."

My generated archetype does not have an archetype.xml. It does have an
archetype-metadata.xml file though. There aren't any errors in the
output from calling archetype:create-from-project, just a couple of
warnings about using platform encoding (Cp1252).

Any thoughts on why this file wasn't generated?

Thanks in advance!

Shelli

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


RE: Missing archetype.xml in new archetype created from project

Posted by Shelli Orton <Sh...@sjrb.ca>.
Well, to partially answer one of my questions, it appears I need to fix all my xml config files where the create archetype process changed all references to "<?xml version="1.0" encoding="UTF-8"?>" to "<?xml version="${version}" encoding="UTF-8"?>"

:(

-----Original Message-----
From: Shelli Orton 
Sent: Monday, May 10, 2010 3:06 PM
To: Maven Users List
Subject: RE: Missing archetype.xml in new archetype created from project

Thanks for the link.  Unfortunately it didn't help with my understanding of how to create an archetype or the structure of one.

I'm using Maven 2.2.1.  

I set up a skeleton project (MyProject) that I want to use to create the archetype (minimal classes, mainly config files and the pom.xml set up with the dependencies).  Everything in my project is contained in the MyProject/src directory except for its pom.xml which is under MyProject.

I ran the archetype:create-from-project command for the project.  I now have a new " target\generated-sources\archetype" directory in my project directory which has a pom.xml file in it.  The pom.xml has an artifactId of "Project-archetype" and a a packaging of "maven-archetype".

It also has two sub-directories:

  MyProject\target\generated-sources\archetype\src
  MyProject\target\generated-sources\archetype\target

Both of these subdirectories contains a pom.xml and an archetype-metadata.xml which are identical.

What exactly is the archetype? Everything under the MyProject\target directory or one of these directories:

  MyProject\target\generated-sources\archetype\
  MyProject\target\generated-sources\archetype\src
  MyProject\target\generated-sources\archetype\target

Do I need to update any files before installing the archetype?  If so which ones?

Thanks in advance for all help.

Shelli

-----Original Message-----
From: Hervé BOUTEMY [mailto:herve.boutemy@free.fr] 
Sent: Thursday, May 06, 2010 1:54 PM
To: Maven Users List
Subject: Re: Missing archetype.xml in new archetype created from project

perhaps http://maven.apache.org/guides/mini/guide-creating-archetypes.html 
will help you
It has been written for 1.x (old) archetype, but principles are the same

Regards,

Hervé

Le mercredi 05 mai 2010, Shelli Orton a écrit :
> Thank you.
> 
> Is there any documentation (online or paper) that is better than what's in
> the Maven documentation
> (http://maven.apache.org/archetype/maven-archetype-plugin/create-from-proj
> ect-mojo.html and
> http://maven.apache.org/archetype/maven-archetype-plugin/advanced-usage.ht
> ml)?  Something that includes some explanation as to what is being
> done/created and why?  For someone new to Maven, most of the documentation
> is very cryptic.
> 
> Thanks again!
> 
> -----Original Message-----
> From: Hervé BOUTEMY [mailto:herve.boutemy@free.fr]
> Sent: Wednesday, May 05, 2010 3:37 PM
> To: Maven Users List
> Subject: Re: Missing archetype.xml in new archetype created from project
> 
> see http://jira.codehaus.org/browse/ARCHETYPE-292
> 
> archetype.xml is "old" archetype descriptor
> 
> Regards,
> 
> Hervé
> 
> Le mercredi 05 mai 2010, Shelli Orton a écrit :
> > Hi,
> > 
> > I am using Maven 2.2.1. and am new to Maven. I am trying to create an
> > archetype based on an existing project. I have been using this blog post
> > as a guide: http://blog.inflinx.com/category/m2eclipse/
> > 
> > Step 7 says "The next step is to verify that the generated archetype.xml
> > (located under srcmainresourcesMETA-INFmaven (sic)) has all the files
> > listed and they are located in the right directories."
> > 
> > My generated archetype does not have an archetype.xml. It does have an
> > archetype-metadata.xml file though. There aren't any errors in the
> > output from calling archetype:create-from-project, just a couple of
> > warnings about using platform encoding (Cp1252).
> > 
> > Any thoughts on why this file wasn't generated?
> > 
> > Thanks in advance!
> > 
> > Shelli
> > 
> > ---------------------------------------------------------------------
> > 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
> 
> 
> ---------------------------------------------------------------------
> 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


---------------------------------------------------------------------
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: Missing archetype.xml in new archetype created from project

Posted by Shelli Orton <Sh...@sjrb.ca>.
Thanks for the link.  Unfortunately it didn't help with my understanding of how to create an archetype or the structure of one.

I'm using Maven 2.2.1.  

I set up a skeleton project (MyProject) that I want to use to create the archetype (minimal classes, mainly config files and the pom.xml set up with the dependencies).  Everything in my project is contained in the MyProject/src directory except for its pom.xml which is under MyProject.

I ran the archetype:create-from-project command for the project.  I now have a new " target\generated-sources\archetype" directory in my project directory which has a pom.xml file in it.  The pom.xml has an artifactId of "Project-archetype" and a a packaging of "maven-archetype".

It also has two sub-directories:

  MyProject\target\generated-sources\archetype\src
  MyProject\target\generated-sources\archetype\target

Both of these subdirectories contains a pom.xml and an archetype-metadata.xml which are identical.

What exactly is the archetype? Everything under the MyProject\target directory or one of these directories:

  MyProject\target\generated-sources\archetype\
  MyProject\target\generated-sources\archetype\src
  MyProject\target\generated-sources\archetype\target

Do I need to update any files before installing the archetype?  If so which ones?

Thanks in advance for all help.

Shelli

-----Original Message-----
From: Hervé BOUTEMY [mailto:herve.boutemy@free.fr] 
Sent: Thursday, May 06, 2010 1:54 PM
To: Maven Users List
Subject: Re: Missing archetype.xml in new archetype created from project

perhaps http://maven.apache.org/guides/mini/guide-creating-archetypes.html 
will help you
It has been written for 1.x (old) archetype, but principles are the same

Regards,

Hervé

Le mercredi 05 mai 2010, Shelli Orton a écrit :
> Thank you.
> 
> Is there any documentation (online or paper) that is better than what's in
> the Maven documentation
> (http://maven.apache.org/archetype/maven-archetype-plugin/create-from-proj
> ect-mojo.html and
> http://maven.apache.org/archetype/maven-archetype-plugin/advanced-usage.ht
> ml)?  Something that includes some explanation as to what is being
> done/created and why?  For someone new to Maven, most of the documentation
> is very cryptic.
> 
> Thanks again!
> 
> -----Original Message-----
> From: Hervé BOUTEMY [mailto:herve.boutemy@free.fr]
> Sent: Wednesday, May 05, 2010 3:37 PM
> To: Maven Users List
> Subject: Re: Missing archetype.xml in new archetype created from project
> 
> see http://jira.codehaus.org/browse/ARCHETYPE-292
> 
> archetype.xml is "old" archetype descriptor
> 
> Regards,
> 
> Hervé
> 
> Le mercredi 05 mai 2010, Shelli Orton a écrit :
> > Hi,
> > 
> > I am using Maven 2.2.1. and am new to Maven. I am trying to create an
> > archetype based on an existing project. I have been using this blog post
> > as a guide: http://blog.inflinx.com/category/m2eclipse/
> > 
> > Step 7 says "The next step is to verify that the generated archetype.xml
> > (located under srcmainresourcesMETA-INFmaven (sic)) has all the files
> > listed and they are located in the right directories."
> > 
> > My generated archetype does not have an archetype.xml. It does have an
> > archetype-metadata.xml file though. There aren't any errors in the
> > output from calling archetype:create-from-project, just a couple of
> > warnings about using platform encoding (Cp1252).
> > 
> > Any thoughts on why this file wasn't generated?
> > 
> > Thanks in advance!
> > 
> > Shelli
> > 
> > ---------------------------------------------------------------------
> > 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
> 
> 
> ---------------------------------------------------------------------
> 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


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


Re: Missing archetype.xml in new archetype created from project

Posted by Hervé BOUTEMY <he...@free.fr>.
perhaps http://maven.apache.org/guides/mini/guide-creating-archetypes.html 
will help you
It has been written for 1.x (old) archetype, but principles are the same

Regards,

Hervé

Le mercredi 05 mai 2010, Shelli Orton a écrit :
> Thank you.
> 
> Is there any documentation (online or paper) that is better than what's in
> the Maven documentation
> (http://maven.apache.org/archetype/maven-archetype-plugin/create-from-proj
> ect-mojo.html and
> http://maven.apache.org/archetype/maven-archetype-plugin/advanced-usage.ht
> ml)?  Something that includes some explanation as to what is being
> done/created and why?  For someone new to Maven, most of the documentation
> is very cryptic.
> 
> Thanks again!
> 
> -----Original Message-----
> From: Hervé BOUTEMY [mailto:herve.boutemy@free.fr]
> Sent: Wednesday, May 05, 2010 3:37 PM
> To: Maven Users List
> Subject: Re: Missing archetype.xml in new archetype created from project
> 
> see http://jira.codehaus.org/browse/ARCHETYPE-292
> 
> archetype.xml is "old" archetype descriptor
> 
> Regards,
> 
> Hervé
> 
> Le mercredi 05 mai 2010, Shelli Orton a écrit :
> > Hi,
> > 
> > I am using Maven 2.2.1. and am new to Maven. I am trying to create an
> > archetype based on an existing project. I have been using this blog post
> > as a guide: http://blog.inflinx.com/category/m2eclipse/
> > 
> > Step 7 says "The next step is to verify that the generated archetype.xml
> > (located under srcmainresourcesMETA-INFmaven (sic)) has all the files
> > listed and they are located in the right directories."
> > 
> > My generated archetype does not have an archetype.xml. It does have an
> > archetype-metadata.xml file though. There aren't any errors in the
> > output from calling archetype:create-from-project, just a couple of
> > warnings about using platform encoding (Cp1252).
> > 
> > Any thoughts on why this file wasn't generated?
> > 
> > Thanks in advance!
> > 
> > Shelli
> > 
> > ---------------------------------------------------------------------
> > 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
> 
> 
> ---------------------------------------------------------------------
> 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: Missing archetype.xml in new archetype created from project

Posted by Shelli Orton <Sh...@sjrb.ca>.
Unfortunatley I don't know enough to update the docs myself.  :(

Shelli

-----Original Message-----
From: Wayne Fay [mailto:waynefay@gmail.com] 
Sent: Wednesday, May 05, 2010 5:06 PM
To: Maven Users List
Subject: Re: Missing archetype.xml in new archetype created from project

> For someone new to Maven, most of the documentation is very cryptic.

This is simply the state of things today; we've discussed this more
than once on this list. Patches to improve the docs are always
appreciated!

Wayne

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


Re: Missing archetype.xml in new archetype created from project

Posted by Wayne Fay <wa...@gmail.com>.
> For someone new to Maven, most of the documentation is very cryptic.

This is simply the state of things today; we've discussed this more
than once on this list. Patches to improve the docs are always
appreciated!

Wayne

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


RE: Missing archetype.xml in new archetype created from project

Posted by Shelli Orton <Sh...@sjrb.ca>.
Thank you.

Is there any documentation (online or paper) that is better than what's in the Maven documentation (http://maven.apache.org/archetype/maven-archetype-plugin/create-from-project-mojo.html and http://maven.apache.org/archetype/maven-archetype-plugin/advanced-usage.html)?  Something that includes some explanation as to what is being done/created and why?  For someone new to Maven, most of the documentation is very cryptic.

Thanks again!

-----Original Message-----
From: Hervé BOUTEMY [mailto:herve.boutemy@free.fr] 
Sent: Wednesday, May 05, 2010 3:37 PM
To: Maven Users List
Subject: Re: Missing archetype.xml in new archetype created from project

see http://jira.codehaus.org/browse/ARCHETYPE-292

archetype.xml is "old" archetype descriptor

Regards,

Hervé

Le mercredi 05 mai 2010, Shelli Orton a écrit :
> Hi,
> 
> I am using Maven 2.2.1. and am new to Maven. I am trying to create an
> archetype based on an existing project. I have been using this blog post
> as a guide: http://blog.inflinx.com/category/m2eclipse/
> 
> Step 7 says "The next step is to verify that the generated archetype.xml
> (located under srcmainresourcesMETA-INFmaven (sic)) has all the files
> listed and they are located in the right directories."
> 
> My generated archetype does not have an archetype.xml. It does have an
> archetype-metadata.xml file though. There aren't any errors in the
> output from calling archetype:create-from-project, just a couple of
> warnings about using platform encoding (Cp1252).
> 
> Any thoughts on why this file wasn't generated?
> 
> Thanks in advance!
> 
> Shelli
> 
> ---------------------------------------------------------------------
> 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


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


Re: Missing archetype.xml in new archetype created from project

Posted by Hervé BOUTEMY <he...@free.fr>.
see http://jira.codehaus.org/browse/ARCHETYPE-292

archetype.xml is "old" archetype descriptor

Regards,

Hervé

Le mercredi 05 mai 2010, Shelli Orton a écrit :
> Hi,
> 
> I am using Maven 2.2.1. and am new to Maven. I am trying to create an
> archetype based on an existing project. I have been using this blog post
> as a guide: http://blog.inflinx.com/category/m2eclipse/
> 
> Step 7 says "The next step is to verify that the generated archetype.xml
> (located under srcmainresourcesMETA-INFmaven (sic)) has all the files
> listed and they are located in the right directories."
> 
> My generated archetype does not have an archetype.xml. It does have an
> archetype-metadata.xml file though. There aren't any errors in the
> output from calling archetype:create-from-project, just a couple of
> warnings about using platform encoding (Cp1252).
> 
> Any thoughts on why this file wasn't generated?
> 
> Thanks in advance!
> 
> Shelli
> 
> ---------------------------------------------------------------------
> 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