Reputation: 399
I do not know anything about maven. Recently I downloaded a Android project code and it included pom.xml file. So after searching for hours I manages to properly import it as a maven project. Every thing seems pretty error free but for one item.
Missing artifact org.mapsforge:mapsforge-map:jar:0.3.0
So I looked at my
C:\Users\MWH.m2\repository\org\mapsforge\mapsforge-map\0.3.0
where all of my artifacts are stored. But there is no executable jar file for this mapsforge-map jar. How can I add this jar to this maven project if it is not available in my repository?
Thanks in advance.
Upvotes: 0
Views: 2697
Reputation: 13181
Download the jar file (from https://code.google.com/p/mapsforge/downloads/list ?)
Copy the jar file to your local Maven repository:
mvn install:install-file -DgroupId=org.mapsforge -DartifactId=mapsforge-map -Dversion=0.3.0 -Dpackaging=jar -Dfile=mapsforge-map-0.3.0-jar-with-dependencies.jar(in the directory you stored the
jar
file)Do mvn compile
in your project folder to verify the newly-installed dependency is available.
Upvotes: 3
Reputation: 353
If it is not available in your repository run the "mvn:clean package" command.Maven will automatically download the dependecy for you.
Upvotes: 0