Pessoal,
Comprei o livro Pratical Apache Struts 2 Web 2.0 Projects, mas estou tendo problemas em gerar o archetype do struts2-starter-2.0.9. Alguém já passou pelo mesmo problema se algum puder me ajudar desde já agradeço:
o seguinte erro ocorre:
C:\Workspaces>mvn archetype:create -DgroupId=tutorial -DartifactId=tutorial -Dar
chetypeGroupId=org.apache.struts -DarchetypeArtifactId=struts2-archetype-starter
-DarchetypeVersion=2.0.9-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] [archetype:create]
[WARNING] This goal is deprecated. Please use mvn archetype:generate instead
[INFO] Defaulting package to group ID: tutorial
[INFO] We are using command line specified remote repositories: http://people.ap
ache.org/repo/m2-snapshot-repository
[INFO] snapshot org.apache.struts:struts2-archetype-starter:2.0.9-SNAPSHOT: chec
king for updates from id0
Downloading: http://people.apache.org/repo/m2-snapshot-repository/org/apache/str
uts/struts2-archetype-starter/2.0.9-SNAPSHOT/struts2-archetype-starter-2.0.9-SNA
PSHOT.jar
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Failed to resolve artifact.
GroupId: org.apache.struts
ArtifactId: struts2-archetype-starter
Version: 2.0.9-SNAPSHOT
Reason: Unable to download the artifact from any repository
Try downloading the file manually from the project website.
Then, install it using the command:
mvn install:install-file -DgroupId=org.apache.struts -DartifactId=struts2-ar
chetype-starter -Dversion=2.0.9-SNAPSHOT -Dpackaging=jar -Dfile=/path/to/file
Alternatively, if you host your own repository you can deploy the file there:
mvn deploy:deploy-file -DgroupId=org.apache.struts -DartifactId=struts2-arch
etype-starter -Dversion=2.0.9-SNAPSHOT -Dpackaging=jar -Dfile=/path/to/file -Dur
l=[url] -DrepositoryId=[id]
org.apache.struts:struts2-archetype-starter:jar:2.0.9-SNAPSHOT
from the specified remote repositories:
id0 (http://people.apache.org/repo/m2-snapshot-repository)
[INFO] ------------------------------------------------------------------------
[INFO] For more information, run Maven with the -e switch
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4 seconds
[INFO] Finished at: Thu Aug 14 10:05:00 GMT-03:00 2008
[INFO] Final Memory: 8M/14M
[INFO] ------------------------------------------------------------------------