You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by maestro <ma...@gmail.com> on 2008/05/11 02:42:11 UTC

Maven struts2-archetype-starter error

Hi,


I very new to Struts2 and Maven.

I ran this command with version 2.0.9 on the 6th of May without a problem.


mvn archetype:create   -DgroupId=tutorial \

                       -DartifactId=tutorial \
                       -DarchetypeGroupId=org.apache.struts \
                       -DarchetypeArtifactId=struts2-archetype-starter \
                       -DarchetypeVersion=2.0.5-SNAPSHOT \

-DremoteRepositories=http://people.apache.org/repo/m2-snapshot-repository


When I run it now I get an error.

[INFO] ------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] : org.apache.maven.archetype.exception.ArchetypeGenerationFailure:
Failed to generate project from the old archetype
Failed to generate project from the old archetype


I'm not sure if its a maven problem or a problem with the
struts2-archetype-starter or something else.

Maven version: 2.0.9
Java version: 1.5.0_13 OS name: "mac os x" version: "10.5.2" arch: "i386"
Family: "unix"

Any ideas are appreciated.
- Glenn

Re: Maven struts2-archetype-starter error

Posted by maestro <ma...@gmail.com>.
I have been unable to continue with this until now.
Funny thing is that it is now working.

Perhaps a typo on my part?

I did install m2eclipse and then I ran into the problem.
Not sure that stopping my machine and starting it again would have an
impact?

Anyways thanks for your time and patience!
- Glenn

RE: Maven struts2-archetype-starter error

Posted by "Allen, Daniel" <Da...@kbcfp.com>.
Add a "-e" (or it might be a capital "-E") to the command, and Maven
will print out the stack trace and a little more information about the
problem. That might give you something to work with.

-----Original Message-----
From: maestro [mailto:maestroqc@gmail.com] 
Sent: Saturday, May 10, 2008 8:42 PM
To: Struts Users Mailing List
Subject: Maven struts2-archetype-starter error

Hi,


I very new to Struts2 and Maven.

I ran this command with version 2.0.9 on the 6th of May without a
problem.


mvn archetype:create   -DgroupId=tutorial \

                       -DartifactId=tutorial \
                       -DarchetypeGroupId=org.apache.struts \
                       -DarchetypeArtifactId=struts2-archetype-starter \
                       -DarchetypeVersion=2.0.5-SNAPSHOT \

-DremoteRepositories=http://people.apache.org/repo/m2-snapshot-repositor
y


When I run it now I get an error.

[INFO]
------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO]
------------------------------------------------------------------------
[INFO] :
org.apache.maven.archetype.exception.ArchetypeGenerationFailure:
Failed to generate project from the old archetype
Failed to generate project from the old archetype


I'm not sure if its a maven problem or a problem with the
struts2-archetype-starter or something else.

Maven version: 2.0.9
Java version: 1.5.0_13 OS name: "mac os x" version: "10.5.2" arch:
"i386"
Family: "unix"

Any ideas are appreciated.
- Glenn

-- 
This message may contain confidential, proprietary, or legally privileged information. No confidentiality or privilege is waived by any transmission to an unintended recipient. If you are not an intended recipient, please notify the sender and delete this message immediately. Any views expressed in this message are those of the sender, not those of any entity within the KBC Financial Products group of companies (together referred to as "KBC FP"). 

This message does not create any obligation, contractual or otherwise, on the part of KBC FP. It is not an offer (or solicitation of an offer) of, or a recommendation to buy or sell, any financial product. Any prices or other values included in this message are indicative only, and do not necessarily represent current market prices, prices at which KBC FP would enter into a transaction, or prices at which similar transactions may be carried on KBC FP's own books. The information contained in this message is provided "as is", without representations or warranties, express or implied, of any kind. Past performance is not indicative of future returns.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: Maven struts2-archetype-starter error

Posted by chenxy <ti...@gmail.com>.
i ran the command on WinXP_sp2, and it came to "BUILD SUCCESSFUL", with some
errs and warnings.

Maven version: 2.0.9
Java version: 1.6.0_02

--------------------------------------------------------------
E:\struts2>mvn archetype:create -DgroupId=tutorial -DartifactId=tutorial
-DarchetypeGroupId=org.apache.struts
-DarchetypeArtifactId=struts2-archetype-starter
-DarchetypeVersion=2.0.5-SNAPSHOT -DremoteRepositories=
http://people.apache.org/repo/m2-snapshot-repository
[INFO] Scanning for projects...
[INFO] Searching repository for plugin with prefix: 'archetype'.
[INFO]
------------------------------------------------------------------------
[INFO] Building Maven Default Project
[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
anyresource loader.
[INFO] Velocimacro : error using  VM library template VM_global_library.vm :
org.apache.velocity.exception.ResourceNotFoundException: Unable to find
resource '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
NOTreplace 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: tutorial
[INFO] We are using command line specified remote repositories:
http://people.apache.org/repo/m2-snapshot-repository
[INFO] snapshot org.apache.struts:struts2-archetype-starter:2.0.5-SNAPSHOT:
checking for updates from id0
[INFO]
----------------------------------------------------------------------------
[INFO] Using following parameters for creating Archetype:
struts2-archetype-starter:2.0.5-SNAPSHOT
[INFO]
----------------------------------------------------------------------------
[INFO] Parameter: groupId, Value: tutorial
[INFO] Parameter: packageName, Value: tutorial
[INFO] Parameter: package, Value: tutorial
[INFO] Parameter: artifactId, Value: tutorial
[INFO] Parameter: basedir, Value: E:\struts2
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] ********************* End of debug info from resources from generated
POM ***********************
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference :template =
archetype-resources/src/main/java/HelloWorldAction.java [line 2,column 4] :
$Id is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference :template = archetype-resources/src/main/java/IndexAction.java
[line 2,column 4]: $Id is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference :template = archetype-resources/src/main/java/DateConverter.java
[line 2,column 4] : $Id is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference :template =
archetype-resources/src/main/webapp/WEB-INF/sitemesh.xml [line 5,column 21]
: ${decorators-file} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference :template =
archetype-resources/src/main/webapp/WEB-INF/sitemesh.xml [line 45,column 41]
: ${decorators-file} is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference :template =
archetype-resources/src/test/java/HelloWorldActionTest.java [line 2,column
4] : $Id is not a valid reference.
[WARNING] org.apache.velocity.runtime.exception.ReferenceException:
reference :template = archetype-resources/src/test/java/IndexActionTest.java
[line 2,column 4] : $Id is not a valid reference.
[INFO] Archetype created in dir: E:\struts2\tutorial
[INFO]
------------------------------------------------------------------------
[INFO] BUILD SUCCESSFUL
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 8 seconds
[INFO] Finished at: Mon May 12 15:23:11 CST 2008
[INFO] Final Memory: 5M/9M
[INFO]
------------------------------------------------------------------------