Re: [m2] Trying to create archetype...

2007-08-01 Thread Raphaël Piéroni
archetype:create purpose is to create a project from a defined archetype

to create an archetype, you have the archetype:create-from-project goal

Raphaêl

2007/8/1, Mick Knutson <[EMAIL PROTECTED]>:
>
> SO how can I create an archetype from an existing module I have?
>
>
>
>
> On 8/1/07, Raphaël Piéroni <[EMAIL PROTECTED]> wrote:
> >
> > This is because you did mvn archetype:create in a directory containing a
> > project.
> > And that project has its packaging different from 'pom'.
> >
> > Considering a directory tree of projects, projects descriptors (
> > pom.xmlfiles)
> > located in the leaves of that tree are not constrained but descriptors
> > located
> > at root or junctions must have pom.
> >
> > I'm not sure of this his the correct maven behaviour, but it is the
> > behaviour assumed by the archetype plugin.
> >
> > Hope this help
> >
> > Raphaël
> >
> >
> > 2007/8/1, Mick Knutson <[EMAIL PROTECTED]>:
> > >
> > > I have a mock module that I want to make into an archetype.
> > >
> > > I have my pom.xml:
> > >
> > > http://maven.apache.org/POM/4.0.0";
> > >  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
> > >  xsi:schemaLocation=" http://maven.apache.org/POM/4.0.0
> > > http://maven.apache.org/maven-v4_0_0.xsd";>
> > > 4.0.0
> > >
> > > org.delta.esp.dap.tools.archetypes
> > > c2-bpel-archetype
> > > 1.0.0.0
> > > maven-plugin
> > >
> > > 
> > > org.delta.esp.dap.tools
> > > archetypes
> > > 1.0.0.0
> > > 
> > > 
> > >
> > >
> > > Then my mock structure:
> > >
> > >
> > >
> >
> C:\viewstore\esp_lynx_dap\esp\dap\tools\archetypes\c2-bpel-archetype\src\main\resources\archetype-resources\pom.xml
> > >
> > > http://maven.apache.org/POM/4.0.0";
> > >  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
> > >  xsi:schemaLocation=" http://maven.apache.org/POM/4.0.0
> > > http://maven.apache.org/maven-v4_0_0.xsd";>
> > > 4.0.0
> > >
> > >
> > > ${groupId}
> > > ${version}
> > > ${artifactId}
> > > jar
> > >
> > > 
> > > 
> > > 
> > >
> > >
> > >
> > >
> > > I get this error when I run this command:
> > > mvn archetype:create
> > > -DgroupId=
> > org.delta.esp.dap.tools.archetypes-DartifactId=c2-bpel-archetype
> > > -DarchetypeArtifactId=maven-archetype-archetype
> > >
> > >
> > >
> > >
> C:\viewstore\esp_lynx_dap\esp\dap\tools\archetypes\c2-bpel-archetype>mvn
> > > archetype:create
> > > -DgroupId=org.delta.esp.dap.tools.archetypes-DartifactId=c2-bpel
> > > -archetype  -DarchetypeArtifactId=maven-archetype-archetype
> > > [INFO] Scanning for projects...
> > > [INFO] Searching repository for plugin with prefix: 'archetype'.
> > > [INFO]
> > >
> > >
> >
> 
> > > [INFO] Building Unnamed -
> > >
> >
> org.delta.esp.dap.tools.archetypes:c2-bpel-archetype:maven-plugin:1.0.0.0
> > > [INFO]task-segment: [archetype:create] (aggregator-style)
> > > [INFO]
> > >
> > >
> >
> 
> > > [INFO] Setting property: classpath.resource.loader.class => '
> > > org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader'.
> > > [INFO] Setting property: velocimacro.messages.on => 'false'.
> > > [INFO] Setting property: resource.loader => 'classpath'.
> > > [INFO] Setting property: resource.manager.logwhenfound => 'false'.
> > > [INFO] **
> > > [INFO] Starting Jakarta Velocity v1.4
> > > [INFO] RuntimeInstance initializing.
> > > [INFO] Default Properties File:
> > > org\apache\velocity\runtime\defaults\velocity.properties
> > > [INFO] Default ResourceManager initializing. (class
> > > org.apache.velocity.runtime.resource.ResourceManagerImpl)
> > > [INFO] Resource Loader Instantiated:
> > > org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader
> > > [INFO] ClasspathResourceLoader : initialization starting.
> > > [INFO] ClasspathResourceLoader : initialization complete.
> > > [INFO] ResourceCache : initialized. (class
> > > org.apache.velocity.runtime.resource.ResourceCacheImpl)
> > > [INFO] Default ResourceManager initialization complete.
> > > [INFO] Loaded System Directive:
> > > org.apache.velocity.runtime.directive.Literal
> > > [INFO] Loaded System Directive:
> > > org.apache.velocity.runtime.directive.Macro
> > > [INFO] Loaded System Directive:
> > > org.apache.velocity.runtime.directive.Parse
> > > [INFO] Loaded System Directive:
> > > org.apache.velocity.runtime.directive.Include
> > > [INFO] Loaded System Directive:
> > > org.apache.velocity.runtime.directive.Foreach
> > > [INFO] Created: 20 parsers.
> > > [INFO] Velocimacro : initialization starting.
> > > [INFO] Velocimacro : adding VMs from VM library template :
> > > VM_global_library.vm
> > > [ERROR] ResourceManager : unable to find resource
> 'VM_global_library.vm'
> > > in
> > > any resource loader.
> > > [INFO] Velocimacro :

Re: [m2] Trying to create archetype...

2007-08-01 Thread Mick Knutson
SO how can I create an archetype from an existing module I have?




On 8/1/07, Raphaël Piéroni <[EMAIL PROTECTED]> wrote:
>
> This is because you did mvn archetype:create in a directory containing a
> project.
> And that project has its packaging different from 'pom'.
>
> Considering a directory tree of projects, projects descriptors (
> pom.xmlfiles)
> located in the leaves of that tree are not constrained but descriptors
> located
> at root or junctions must have pom.
>
> I'm not sure of this his the correct maven behaviour, but it is the
> behaviour assumed by the archetype plugin.
>
> Hope this help
>
> Raphaël
>
>
> 2007/8/1, Mick Knutson <[EMAIL PROTECTED]>:
> >
> > I have a mock module that I want to make into an archetype.
> >
> > I have my pom.xml:
> >
> > http://maven.apache.org/POM/4.0.0";
> >  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
> >  xsi:schemaLocation=" http://maven.apache.org/POM/4.0.0
> > http://maven.apache.org/maven-v4_0_0.xsd";>
> > 4.0.0
> >
> > org.delta.esp.dap.tools.archetypes
> > c2-bpel-archetype
> > 1.0.0.0
> > maven-plugin
> >
> > 
> > org.delta.esp.dap.tools
> > archetypes
> > 1.0.0.0
> > 
> > 
> >
> >
> > Then my mock structure:
> >
> >
> >
> C:\viewstore\esp_lynx_dap\esp\dap\tools\archetypes\c2-bpel-archetype\src\main\resources\archetype-resources\pom.xml
> >
> > http://maven.apache.org/POM/4.0.0";
> >  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
> >  xsi:schemaLocation=" http://maven.apache.org/POM/4.0.0
> > http://maven.apache.org/maven-v4_0_0.xsd";>
> > 4.0.0
> >
> >
> > ${groupId}
> > ${version}
> > ${artifactId}
> > jar
> >
> > 
> > 
> > 
> >
> >
> >
> >
> > I get this error when I run this command:
> > mvn archetype:create
> > -DgroupId=
> org.delta.esp.dap.tools.archetypes-DartifactId=c2-bpel-archetype
> > -DarchetypeArtifactId=maven-archetype-archetype
> >
> >
> >
> > C:\viewstore\esp_lynx_dap\esp\dap\tools\archetypes\c2-bpel-archetype>mvn
> > archetype:create
> > -DgroupId=org.delta.esp.dap.tools.archetypes-DartifactId=c2-bpel
> > -archetype  -DarchetypeArtifactId=maven-archetype-archetype
> > [INFO] Scanning for projects...
> > [INFO] Searching repository for plugin with prefix: 'archetype'.
> > [INFO]
> >
> >
> 
> > [INFO] Building Unnamed -
> >
> org.delta.esp.dap.tools.archetypes:c2-bpel-archetype:maven-plugin:1.0.0.0
> > [INFO]task-segment: [archetype:create] (aggregator-style)
> > [INFO]
> >
> >
> 
> > [INFO] Setting property: classpath.resource.loader.class => '
> > org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader'.
> > [INFO] Setting property: velocimacro.messages.on => 'false'.
> > [INFO] Setting property: resource.loader => 'classpath'.
> > [INFO] Setting property: resource.manager.logwhenfound => 'false'.
> > [INFO] **
> > [INFO] Starting Jakarta Velocity v1.4
> > [INFO] RuntimeInstance initializing.
> > [INFO] Default Properties File:
> > org\apache\velocity\runtime\defaults\velocity.properties
> > [INFO] Default ResourceManager initializing. (class
> > org.apache.velocity.runtime.resource.ResourceManagerImpl)
> > [INFO] Resource Loader Instantiated:
> > org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader
> > [INFO] ClasspathResourceLoader : initialization starting.
> > [INFO] ClasspathResourceLoader : initialization complete.
> > [INFO] ResourceCache : initialized. (class
> > org.apache.velocity.runtime.resource.ResourceCacheImpl)
> > [INFO] Default ResourceManager initialization complete.
> > [INFO] Loaded System Directive:
> > org.apache.velocity.runtime.directive.Literal
> > [INFO] Loaded System Directive:
> > org.apache.velocity.runtime.directive.Macro
> > [INFO] Loaded System Directive:
> > org.apache.velocity.runtime.directive.Parse
> > [INFO] Loaded System Directive:
> > org.apache.velocity.runtime.directive.Include
> > [INFO] Loaded System Directive:
> > org.apache.velocity.runtime.directive.Foreach
> > [INFO] Created: 20 parsers.
> > [INFO] Velocimacro : initialization starting.
> > [INFO] Velocimacro : adding VMs from VM library template :
> > VM_global_library.vm
> > [ERROR] ResourceManager : unable to find resource 'VM_global_library.vm'
> > in
> > any resource loader.
> > [INFO] Velocimacro : error using  VM library template
> VM_global_library.vm
> > :
> > org.apache.velocity.exception.ResourceNotFoundException: Unable to find
> > resour
> > ce 'VM_global_library.vm'
> > [INFO] Velocimacro :  VM library template macro registration complete.
> > [INFO] Velocimacro : allowInline = true : VMs can be defined inline in
> > templates
> > [INFO] Velocimacro : allowInlineToOverride = false : VMs defined inline
> > may
> > NOT replace previous VM definitions
> > [INFO] Velocim

Re: [m2] Trying to create archetype...

2007-08-01 Thread Raphaël Piéroni
This is because you did mvn archetype:create in a directory containing a
project.
And that project has its packaging different from 'pom'.

Considering a directory tree of projects, projects descriptors (pom.xmlfiles)
located in the leaves of that tree are not constrained but descriptors
located
at root or junctions must have pom.

I'm not sure of this his the correct maven behaviour, but it is the
behaviour assumed by the archetype plugin.

Hope this help

Raphaël


2007/8/1, Mick Knutson <[EMAIL PROTECTED]>:
>
> I have a mock module that I want to make into an archetype.
>
> I have my pom.xml:
>
> http://maven.apache.org/POM/4.0.0";
>  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
>  xsi:schemaLocation=" http://maven.apache.org/POM/4.0.0
> http://maven.apache.org/maven-v4_0_0.xsd";>
> 4.0.0
>
> org.delta.esp.dap.tools.archetypes
> c2-bpel-archetype
> 1.0.0.0
> maven-plugin
>
> 
> org.delta.esp.dap.tools
> archetypes
> 1.0.0.0
> 
> 
>
>
> Then my mock structure:
>
>
> C:\viewstore\esp_lynx_dap\esp\dap\tools\archetypes\c2-bpel-archetype\src\main\resources\archetype-resources\pom.xml
>
> http://maven.apache.org/POM/4.0.0";
>  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
>  xsi:schemaLocation=" http://maven.apache.org/POM/4.0.0
> http://maven.apache.org/maven-v4_0_0.xsd";>
> 4.0.0
>
>
> ${groupId}
> ${version}
> ${artifactId}
> jar
>
> 
> 
> 
>
>
>
>
> I get this error when I run this command:
> mvn archetype:create
> -DgroupId=org.delta.esp.dap.tools.archetypes-DartifactId=c2-bpel-archetype
> -DarchetypeArtifactId=maven-archetype-archetype
>
>
>
> C:\viewstore\esp_lynx_dap\esp\dap\tools\archetypes\c2-bpel-archetype>mvn
> archetype:create
> -DgroupId=org.delta.esp.dap.tools.archetypes-DartifactId=c2-bpel
> -archetype  -DarchetypeArtifactId=maven-archetype-archetype
> [INFO] Scanning for projects...
> [INFO] Searching repository for plugin with prefix: 'archetype'.
> [INFO]
>
> 
> [INFO] Building Unnamed -
> org.delta.esp.dap.tools.archetypes:c2-bpel-archetype:maven-plugin:1.0.0.0
> [INFO]task-segment: [archetype:create] (aggregator-style)
> [INFO]
>
> 
> [INFO] Setting property: classpath.resource.loader.class => '
> org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader'.
> [INFO] Setting property: velocimacro.messages.on => 'false'.
> [INFO] Setting property: resource.loader => 'classpath'.
> [INFO] Setting property: resource.manager.logwhenfound => 'false'.
> [INFO] **
> [INFO] Starting Jakarta Velocity v1.4
> [INFO] RuntimeInstance initializing.
> [INFO] Default Properties File:
> org\apache\velocity\runtime\defaults\velocity.properties
> [INFO] Default ResourceManager initializing. (class
> org.apache.velocity.runtime.resource.ResourceManagerImpl)
> [INFO] Resource Loader Instantiated:
> org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader
> [INFO] ClasspathResourceLoader : initialization starting.
> [INFO] ClasspathResourceLoader : initialization complete.
> [INFO] ResourceCache : initialized. (class
> org.apache.velocity.runtime.resource.ResourceCacheImpl)
> [INFO] Default ResourceManager initialization complete.
> [INFO] Loaded System Directive:
> org.apache.velocity.runtime.directive.Literal
> [INFO] Loaded System Directive:
> org.apache.velocity.runtime.directive.Macro
> [INFO] Loaded System Directive:
> org.apache.velocity.runtime.directive.Parse
> [INFO] Loaded System Directive:
> org.apache.velocity.runtime.directive.Include
> [INFO] Loaded System Directive:
> org.apache.velocity.runtime.directive.Foreach
> [INFO] Created: 20 parsers.
> [INFO] Velocimacro : initialization starting.
> [INFO] Velocimacro : adding VMs from VM library template :
> VM_global_library.vm
> [ERROR] ResourceManager : unable to find resource 'VM_global_library.vm'
> in
> any resource loader.
> [INFO] Velocimacro : error using  VM library template VM_global_library.vm
> :
> org.apache.velocity.exception.ResourceNotFoundException: Unable to find
> resour
> ce 'VM_global_library.vm'
> [INFO] Velocimacro :  VM library template macro registration complete.
> [INFO] Velocimacro : allowInline = true : VMs can be defined inline in
> templates
> [INFO] Velocimacro : allowInlineToOverride = false : VMs defined inline
> may
> NOT replace previous VM definitions
> [INFO] Velocimacro : allowInlineLocal = false : VMs defined inline will be
> global in scope if allowed.
> [INFO] Velocimacro : initialization complete.
> [INFO] Velocity successfully started.
> [INFO] [archetype:create]
> [INFO] Defaulting package to group ID: org.delta.esp.dap.tools.archetypes
> [INFO]
>
> 
> [INFO] Using following parameter