You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by chandrasheker <ch...@gmail.com> on 2011/12/21 05:12:59 UTC

maven repositories(how to

Hi ,
I am using maven 3.0.3.how to configure maven official repository and my
company remote repository.
It is always connect to repo1 central repository.plz help me.
                   <mirror>
	      <id>repository</id>
	      <mirrorOf>*,!repo1</mirrorOf>
	      <name>ConsRepo</name>
	      <url>http://mycompany.com/repository</url>
    	</mirror>
                    <mirror>
	      <id>repo1</id>
	      <mirrorOf>external:*</mirrorOf>
	      <name>maven2</name>
	      <url>http://repo1.maven.org/maven2</url>
    	</mirror>
Plz help me
Thanks & Regards,
shekarchandra

--
View this message in context: http://maven.40175.n5.nabble.com/maven-repositories-how-to-tp5090872p5090872.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: maven repositories(how to

Posted by Anders Hammar <an...@hammar.net>.
First of all, if you have a company repository you should probably
talk to the people managing it about this. They should be able to
provide support. Also, you relying on other repos than the internal
one might not work in the big picture as other people consuming your
artifacts will have to do that as well (although central should be one
of the common ones).

Secondly, your company internal repo should be a repo manager which
should proxy Maven central (repo1) in a correct setup IMO. So you
shouldn't need to add it. Again, talk to the people managing your
repo.

Lastly, Maven central is already declared as a repo in the super-POM
(with the id 'central'). So it should be possible to accomplish by
removing the second mirror element and changing the mirrorOf string of
the first element to "*,!central" (quotes not included). This relies
on this id not to change in the super-POM so it's not future proof
though. This can be solved by re-declaration Maven central as a repo
in settings.xml.

But, once again, please talk to your internal repository staff first.

/Anders

On Wed, Dec 21, 2011 at 05:12, chandrasheker <ch...@gmail.com> wrote:
> Hi ,
> I am using maven 3.0.3.how to configure maven official repository and my
> company remote repository.
> It is always connect to repo1 central repository.plz help me.
>                   <mirror>
>              <id>repository</id>
>              <mirrorOf>*,!repo1</mirrorOf>
>              <name>ConsRepo</name>
>              <url>http://mycompany.com/repository</url>
>        </mirror>
>                    <mirror>
>              <id>repo1</id>
>              <mirrorOf>external:*</mirrorOf>
>              <name>maven2</name>
>              <url>http://repo1.maven.org/maven2</url>
>        </mirror>
> Plz help me
> Thanks & Regards,
> shekarchandra
>
> --
> View this message in context: http://maven.40175.n5.nabble.com/maven-repositories-how-to-tp5090872p5090872.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
>

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