user1564943
user1564943

Reputation: 11

Maven Repository

I have downloaded all artifacts in maven repository. Now I copied the repository folder content to other computer running maven. I have to access this new repository for maven commands but it is trying to connect to net for downloading artifacts required. What should I do?? Is there any way of using such repository created manually??

Upvotes: 1

Views: 720

Answers (3)

MozenRath
MozenRath

Reputation: 10040

This is happening because you might have a different version of Maven on your new machine and thus, it will try to install all the new compatible plugins while you try to build it. So there is no way to get around it except for using exactly the same maven version and same settings

Upvotes: 0

DerMiggel
DerMiggel

Reputation: 493

Are you using snapshot versions of your dependencies? If so, Maven might still try to connect to a remote repository to check if there is a new version available. However, you can avoid this by using -o (=offline), like this:

mvn -o <your_command>

Upvotes: 1

tom
tom

Reputation: 2745

Did you set the correct path to the maven repository in your settings.xml file?

Upvotes: 0

Related Questions