How to install a jar manually in local maven repository?

Problem Statement: Your pom.xml dependencies is not able to download a certain jar from the repository.

You can manually download the jar and add it to your local maven repository.

Assuming this dependency (mentioned in pom.xml) fails (because the jar fails to download):


Then download hibernate-entitymanager-3.3.2.GA manually, and run the command:
mvn install:install-file -DgroupId=org.hibernate -DartifactId=hibernate-entitymanager -Dversion=3.3.2.GA -Dpackaging=jar -Dfile=./hibernate-entitymanager-3.3.2.GA.jar

Thats it, you are all set.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: