Can't use maven2 (offline)
I'm back. First, thank you for your answers. Sorry to say this but the more I try it, the more I find it strange (under linux) ... and I can't start using a tool with such questions haunting me. Question 1 : I work under Linux (this could be important because I never succeeded in using the automatic update under linux but it worked as soon as I tried under Windows, even with a proxy configuration). So I used the automatic update with a windows machine, and then transferred the local repository to my linux secured network. I want this copy to become my remote repository. I tried the solution of a "single mirror" entry with mirrorOf set to central in the settings.xml and it works ONLY IF I rename all the maven-metadata-central.xml files to maven-metadata.xml. When I use "mvn -c archetype:create ...", after the "download" to my $HOME/.m2/repository, these files have been automatically renamed again to maven-metadata-central.xml. Is it a normal behaviour ? (not intuitive anyway) Question 2 : Now, I would like to use the way, instead of mirror. What I can say is that whatever the id of the repository ("central" or not), it always failed BUT with the following settings : true true _REPO_1 My repo1 file:///mypath/ibiblio/maven2 true true _REPO_2_ My repo2 file:///mypath/ibiblio/maven2 MyProfile MyProfile IT HAS BEEN WORKING ... FOR AN HOUR ... Among the output, I could see the proof that my repository was taken into account (with an id not equal to central) : ... [INFO] org.apache.maven.plugins: checking for updates from _REPO_2_ [INFO] org.apache.maven.plugins: checking for updates from central ... I have to say that I don't know very well the usefulness of , , and but as it was working, I made preciously a copy of settings.xml in a safe place. It was the only time I succeeded using repositories. The day after, no way. It worked no more. It's a mystery. So : have you heard of an intermittent problem with mvn and/or Linux and/or the file:/// protocol ? Anybody having the same problem ? Thank you. _ Apprenez à lutter contre le spam ! http://go.msn.fr/10-channel/80-security/spam/default.asp - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Can't use maven2 (offline)
Offline actually avoids all remote repositories (even file ones, as they might be on a shared drive). But I had said that offline=false. So, I don't understand why my defined repository is ignored. On 11/8/05, Eric Parpal <[EMAIL PROTECTED]> wrote: > I tried with offline=false and file:///mypath/ibiblio/maven2 (in > settings.xml and in the command line). So, assuming that I don't set offline to true, what is wrong with my settings : repo1 repo1 file:/mypath/ibiblio/maven2 repo2 repo2 file:/mypath/ibiblio/maven2 MyProfile MyProfile Moreover, what's the difference between a and a ? Thanks. _ 10 Mo pour vos pièces jointes avec MSN Hotmail ! http://www.imagine-msn.com/hotmail/default.aspx?locale=fr-FR - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Can't use maven2 (offline)
I tried with offline=false and file:///mypath/ibiblio/maven2 (in settings.xml and in the command line). Always the same message. Finally, are you sure you got all the dependencies of the archetype plugin and the archetype artifact itself? No I am not sure because no message warns me. The character '*' meaning that all subfiles and subdirectories have been downloaded, the content of my /mypath/ibiblio/maven2 directory is : /mypath/ibiblio/maven2/org/apache/maven/archetypes/* /mypath/ibiblio/maven2/plugins/org/apache/maven/plugins/maven-archetype-plugin/* /mypath/ibiblio/maven2/plugins/org/apache/maven/plugins/maven-install-plugin/* /mypath/ibiblio/maven2/plugins/org/apache/maven/plugins/index.html /mypath/ibiblio/maven2/plugins/org/apache/maven/plugins/maven-metadata.xml /mypath/ibiblio/maven2/plugins/org/apache/maven/plugins/maven-metadata.xml.md5 /mypath/ibiblio/maven2/plugins/org/apache/maven/plugins/maven-metadata.xml.sha1 /mypath/ibiblio/maven2/plugins/org/apache/maven/plugins/plugins.xml.md5 /mypath/ibiblio/maven2/plugins/org/apache/maven/plugins/plugins.xml.sha1 /mypath/ibiblio/maven2/org/apache/maven/plugins/maven-archetype-plugin/* /mypath/ibiblio/maven2/org/apache/maven/plugins/maven-metadata.xml /mypath/ibiblio/maven2/org/apache/maven/plugins/maven-metadata.xml.md5 /mypath/ibiblio/maven2/org/apache/maven/plugins/maven-metadata.xml.sha1 NB : I don't know the difference between org/apache/maven/plugins and plugins/org/apache/maven, I took both If you are sure you have all the dependencies, and that your repository path is correct, you can try the fully specified invocation, which looks like: mvn ::: I'm sure of nothing. I used url=file:///mypath/ibiblio/maven2. Is it right ? (I supposed that this path should stop at the directory "maven2", as the "internet" one does : http://www.ibiblio.org/maven2). Do I have to define it as a "pluginRepository" or as a "repository" ? (In doubt, I did both) Then, I tried mvn org.apache.maven.plugins:maven-archetype-plugin:1.0-alpha-3:create -D... and gets another message (thanks for this!) : "Downloading http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-install-plugin/1.0-alpha-3/maven-archetype-plugin-1.0-alpha-3.pom"; ... Error getting pom ... from the specified remote repositories: central (http://repo1.maven.org/maven2)" So, I can't see mention of my repository. I don't know why. I might have missed something. Besides, when I look for this file in the internet repository, I can't find it. Any help or suggestion will be welcomed. Thanks. _ Une chance par jour de gagner un voyage au soleil avec Magic Search ! http://www.magicsearch.fr - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Can't use maven2 (offline)
My working network has no connection to internet (no way). I download and copied the part of www.ibiblio.org/maven2 that seemed to me necessary to launch the first command of the Quick Start (mvn archetype:create), let's say under file:/mypath/ibiblio/maven2. I tried several things, one by one, or combined. I always failed and got the same message (the plugin org.apache.maven.plugins:maven-archetype-plugin does not exist or no valid version could be found). My big problem is that maven never says to me what's the real problem ! Whatever the way, always the same message. No way to know if my mirror or my repository is ignored, or is taken into account but not correct, or else. Here are the things I tried : * a mirror defined in my settings.xml : central mirror1 file:/mypath/ibiblio/maven2 mirror1 * a profile/repository defined in my settings.xml : repo1 repo1 file:/mypath/ibiblio/maven2 repo2 repo2 file:/mypath/ibiblio/maven2 MyProfile MyProfile (and trying with or without -PMyProfile in the command line) * true in my settings.xml * -DremoteRepositories=file:/mypath/ibiblio/maven2 on the command line In fact, I think I will be obliged to use maven 1 again if nobody can help me :-( _ Tout savoir sur la sécurité de vos enfants sur Internet ! http://go.msn.fr/10-channel/80-security/protection/default.asp - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[M2] Manual installation of plugins
Are these two networks completly separated or is it possible to reach the one machine, that has an internet connection? If so, you can install there the Maven-proxy. Unfortunately, there is the Internet network and there is a secured network. No way to connect them, even for a minute ... So, I would like to install manually all the necessaries files but I don't know exactly what files are missing and where to copy them. :-( _ Une chance par jour de gagner un voyage au soleil avec Magic Search ! http://www.magicsearch.fr - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[M2] Manual installation of plugins
Hello, I installed Maven2 on a protected network not connected to Internet. On the other side, I installed Maven2 on a machine connected to the internet network in the aim to download automatically all the necessaries files (and then to transfer them to the other network). I get an error message (see below) when I launch the following command (taken from the Getting Started Guide) : mvn archetype:create -DgroupId=com.dcn.app -DartifactId=my-app I get the same error trying with more options (I saw these options in some mails of the maven archive users list) : mvn -e archetype:create -DgroupId=com.dcn.app -DartifactId=my-app -DarchetypeGroupId=org.apache.maven.archetypes -DarchetypeArtifactId=maven-archetype-site -DarchetypeVersion=1.0-alpha-2 Here is the output : + Error stacktraces are turned on. [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] Trace org.apache.maven.lifecycle.LifecycleExecutionException: The plugin 'org.apache.maven.plugins:maven-archetype-plugin' does not exist or no valid version could be found at org.apache.maven.lifecycle.DefaultLifecycleExecutor.verifyPlugin(DefaultLifecycleExecutor.java:1124) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.getMojoDescriptor(DefaultLifecycleExecutor.java:1356) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.segmentTaskListByAggregationNeeds(DefaultLifecycleExecutor.java:376) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:132) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:316) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:113) at org.apache.maven.cli.MavenCli.main(MavenCli.java:249) 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:324) 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) Caused by: org.apache.maven.plugin.version.PluginVersionNotFoundException: The plugin 'org.apache.maven.plugins:maven-archetype-plugin' does not exist or no valid version could be found at org.apache.maven.plugin.version.DefaultPluginVersionManager.resolvePluginVersion(DefaultPluginVersionManager.java:225) at org.apache.maven.plugin.version.DefaultPluginVersionManager.resolvePluginVersion(DefaultPluginVersionManager.java:87) at org.apache.maven.plugin.DefaultPluginManager.verifyPlugin(DefaultPluginManager.java:158) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.verifyPlugin(DefaultLifecycleExecutor.java:1095) ... 14 more [INFO] [INFO] Total time: 1 second [INFO] Finished at: Thu Oct 27 15:49:15 CEST 2005 [INFO] Final Memory: 1M/2M [INFO] I precise that I tried with a proxy configuration in ~/.m2/settings.xml and I also tried with the -Dmaven.proxy.host and -Dmaven.proxy.port options but I always get the same result. So please, here are my questions : Did I miss something ? As a workaround, what are the required files and how to manually installed them ? That is : do I have to download http://www.ibiblio.org/maven2/plugins/org/apache/maven/plugins/maven-archetype-plugin/1.0-alpha-1/maven-archetype-plugin-1.0-alpha-1.jar OR http://www.ibiblio.org/maven2/org/apache/maven/archetypes/maven-archetype-site/1.0-alpha-2/maven-archetype-site-1.0-alpha-2.jar OR both ? (in fact, what is the difference ?) and where do I have to copy this (or these) files ? Thank you for your help. Eric _ Tout savoir sur la sécurité de vos enfants sur Internet ! http://go.msn.fr/10-channel/80-security/protection/default.asp - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]