You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Eric Parpal <er...@hotmail.fr> on 2005/11/07 15:02:53 UTC

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 :
<mirror>
	<mirrorOf>central</mirrorOf>
	<name>mirror1</name>
	<url>file:/mypath/ibiblio/maven2</url>
	<id>mirror1</id>
</mirror>

* a profile/repository defined in my settings.xml :
<profiles>
	<profile>
		<repositories>
			<repository>
				<id>repo1</id>
				<name>repo1</name>
				<url>file:/mypath/ibiblio/maven2</url>
			</repository>
		</repositories>
		<pluginRepositories>
			<pluginRepository>
				<id>repo2</id>
				<name>repo2</name>
				<url>file:/mypath/ibiblio/maven2</url>
			</pluginRepository>
		</pluginRepositories>
		<id>MyProfile</id>
	</profile>
	<activeProfiles>
		<activeProfile>MyProfile</activeProfile>
	</activeProfiles>
(and trying with or without -PMyProfile in the command line)

* <offline>true</offline> 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: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Can't use maven2 (offline)

Posted by Antony Stubbs <an...@gmail.com>.
Somre more info about going offline:
http://stubbisms.wordpress.com/2008/08/28/maven-is-to-ant-as-a-nail-gun-is-to-hammer-and-nails-you-need-to-move-on/


Eric Parpal wrote:
> 
> 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 :
> <mirror>
> 	<mirrorOf>central</mirrorOf>
> 	<name>mirror1</name>
> 	<url>file:/mypath/ibiblio/maven2</url>
> 	<id>mirror1</id>
> </mirror>
> 
> * a profile/repository defined in my settings.xml :
> <profiles>
> 	<profile>
> 		<repositories>
> 			<repository>
> 				<id>repo1</id>
> 				<name>repo1</name>
> 				<url>file:/mypath/ibiblio/maven2</url>
> 			</repository>
> 		</repositories>
> 		<pluginRepositories>
> 			<pluginRepository>
> 				<id>repo2</id>
> 				<name>repo2</name>
> 				<url>file:/mypath/ibiblio/maven2</url>
> 			</pluginRepository>
> 		</pluginRepositories>
> 		<id>MyProfile</id>
> 	</profile>
> 	<activeProfiles>
> 		<activeProfile>MyProfile</activeProfile>
> 	</activeProfiles>
> (and trying with or without -PMyProfile in the command line)
> 
> * <offline>true</offline> 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: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 
> 
> 


-----
___________________________

http://stubbisms.wordpress.com http://stubbisms.wordpress.com 
-- 
View this message in context: http://www.nabble.com/Can%27t-use-maven2-%28offline%29-tp1367861p19194263.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Can't use maven2 (offline)

Posted by Antony Stubbs <an...@gmail.com>.
Some more info about going offline:
http://stubbisms.wordpress.com/2008/08/28/maven-is-to-ant-as-a-nail-gun-is-to-hammer-and-nails-you-need-to-move-on/


Eric Parpal wrote:
> 
> 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 :
> <mirror>
> 	<mirrorOf>central</mirrorOf>
> 	<name>mirror1</name>
> 	<url>file:/mypath/ibiblio/maven2</url>
> 	<id>mirror1</id>
> </mirror>
> 
> * a profile/repository defined in my settings.xml :
> <profiles>
> 	<profile>
> 		<repositories>
> 			<repository>
> 				<id>repo1</id>
> 				<name>repo1</name>
> 				<url>file:/mypath/ibiblio/maven2</url>
> 			</repository>
> 		</repositories>
> 		<pluginRepositories>
> 			<pluginRepository>
> 				<id>repo2</id>
> 				<name>repo2</name>
> 				<url>file:/mypath/ibiblio/maven2</url>
> 			</pluginRepository>
> 		</pluginRepositories>
> 		<id>MyProfile</id>
> 	</profile>
> 	<activeProfiles>
> 		<activeProfile>MyProfile</activeProfile>
> 	</activeProfiles>
> (and trying with or without -PMyProfile in the command line)
> 
> * <offline>true</offline> 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: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 
> 
> 


-----
___________________________

http://stubbisms.wordpress.com http://stubbisms.wordpress.com 
-- 
View this message in context: http://www.nabble.com/Can%27t-use-maven2-%28offline%29-tp1367861p19194264.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Can't use maven2 (offline)

Posted by John Casey <jd...@commonjava.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

My initial guess is that since you have <offline/> set to true, it's not
accessing any remote repositories at all, regardless of whether it's got
a local mirror. Have you tried with the local mirror and offline==false?

What files did you copy over? Did you get the metadata files as well as
the jars? Finally, are you sure you got all the dependencies of the
archetype plugin and the archetype artifact itself?

One other thing I'd suggest trying is a triple-slash in your path, like
this:

file:///mypath/ibiblio/maven2

I've personally found the file: URL format to be a bit confusing, and
I'm not 100% sure what will work and what won't. The big problem here
seems to be that it cannot determine from the metadata which version of
the archetype plugin to use...by checking those maven-metadata XML files
in the repository.

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 <groupId>:<artifactId>:<version>:<goal>

Which should pin the plugin version down to a concrete value, and skip
any mucking around with metadata.

Let's find out what works here, and then we'll write up some formal doco
for the next guy. :)

Cheers,

John

Eric Parpal wrote:
| 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 :
| <mirror>
|     <mirrorOf>central</mirrorOf>
|     <name>mirror1</name>
|     <url>file:/mypath/ibiblio/maven2</url>
|     <id>mirror1</id>
| </mirror>
|
| * a profile/repository defined in my settings.xml :
| <profiles>
|     <profile>
|         <repositories>
|             <repository>
|                 <id>repo1</id>
|                 <name>repo1</name>
|                 <url>file:/mypath/ibiblio/maven2</url>
|             </repository>
|         </repositories>
|         <pluginRepositories>
|             <pluginRepository>
|                 <id>repo2</id>
|                 <name>repo2</name>
|                 <url>file:/mypath/ibiblio/maven2</url>
|             </pluginRepository>
|         </pluginRepositories>
|         <id>MyProfile</id>
|     </profile>
|     <activeProfiles>
|         <activeProfile>MyProfile</activeProfile>
|     </activeProfiles>
| (and trying with or without -PMyProfile in the command line)
|
| * <offline>true</offline> 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: users-unsubscribe@maven.apache.org
| For additional commands, e-mail: users-help@maven.apache.org
|
|
|
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (GNU/Linux)

iD8DBQFDb2cJK3h2CZwO/4URAokVAKCAHTIJMhLlLlmWsi90Dbk/SR85rwCfS3MI
VApry+Q+1w5aNnIz0t0wpzE=
=d4Zl
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org