Try to run
   mvn *-U* archetype:create -DgroupId=com.mycompany.app -DartifactId=myApp

The "-U" force plugin updates, thismay solve this issue.

Xavier Outhier a écrit :
Hi all,

I'm sure this is not a cutting edge question.
I've just downloaded and installed Maven.

1)
Well, I simply followed the Installation instructions from page
http://maven.apache.org/download.html#installation


       Windows 2000/XP

  1. Unzip maven-2.0.3-bin.zip to the directory you wish to install
     Maven 2.0.3. These instructions assume you chose C:\Program
     Files\Apache Software Foundation\maven-2.0.3
  2. Add the bin directory to your path, by opening up the system
     properties (WinKey + Pause), selecting the "Advanced" tab, and the
     "Environment Variables" button, then editing the PATH variable in
     the user variables. eg. "C:\Program Files\Apache Software
     Foundation\maven-2.0.3\bin";%PATH%
  3. In the same dialog, make sure that JAVA_HOME is set to the
     location of your JDK, eg. C:\Program Files\Java\jdk1.5.0_02
  4. Run mvn --version to verify that it is correctly installed.


And then I try the first command of the Maven Getting Started Guide
(http://maven.apache.org/guides/getting-started/index.html):

2) But here is what I get:
D:\tmp\sandbox>mvn --version
Maven version: 2.0.4

D:\tmp\sandbox>*mvn archetype:create -DgroupId=com.mycompany.app -DartifactId=myApp*
[INFO] Scanning for projects...
[INFO] Searching repository for plugin with prefix: 'archetype'.
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------ [INFO] The plugin 'org.apache.maven.plugins:maven-archetype-plugin' does not exist or no valid version could be found [INFO] ------------------------------------------------------------------------
[INFO] For more information, run Maven with the -e switch
[INFO] ------------------------------------------------------------------------
[INFO] Total time: < 1 second
[INFO] Finished at: Thu Oct 19 14:37:03 CEST 2006
[INFO] Final Memory: 1M/2M
[INFO] ------------------------------------------------------------------------

D:\tmp\sandbox>mvn -e
+ Error stacktraces are turned on.
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] You must specify at least one goal. Try 'install'
[INFO] ------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.BuildFailureException: You must specify at least one goal. Try 'install' at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:132)
       at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322)
       at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
       at org.apache.maven.cli.MavenCli.main(MavenCli.java:256)
       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:585)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
       at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
       at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
[INFO] ------------------------------------------------------------------------
[INFO] Total time: < 1 second
[INFO] Finished at: Thu Oct 19 14:37:24 CEST 2006
[INFO] Final Memory: 1M/2M
[INFO] ------------------------------------------------------------------------

3) What should I do? Is it a configuration problem? How to install locally the plug-in?

Thanks for any help,

Xavier.


This message contains information that may be privileged or confidential and is 
the property of the Capgemini Group. It is intended only for the person to whom 
it is addressed. If you are not the intended recipient,  you are not authorized 
to read, print, retain, copy, disseminate,  distribute, or use this message or 
any part thereof. If you receive this  message in error, please notify the 
sender immediately and delete all  copies of this message.


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

Reply via email to