0

I have a JAR which can't be found in the Maven Repositories.

So that I use the following command to install into my local repositories

install:install-file -Dfile=C:/FIXApplication/lib/quickfixj-all-1.5.2 -DgroupId=org.quickfixj -DartifactId=quickfixj -Dversion=1.5.2 -Dpackaging=jar -DgeneratePom=true

And the result is successful and I can find the folder under the .m2\repository\org\quickfixj\quickfixj

But when I modify the pom.xml to add the dependency. It said: Missing artifact org.quickfixj:quickfixj:jar:1.5.2

Why this happen? Why can't read the local repositories?

macemers
  • 2,194
  • 6
  • 38
  • 55
  • Try running offline. mvn -o install – Phani Apr 24 '12 at 09:44
  • 1
    Have you checked that the jar is actually inside the m2 repository? I tried your command and left it unchanged and the installation was said to be successful however I do not have your jar and when I went to see if it was present in the M2 repo I saw that the directories had been created but there is no jar inside – Guillaume Polet Apr 24 '12 at 09:56

1 Answers1

0

Though the command did not error, it is quite likely that the local repository does not have the artifact.

Your command has this part

-Dfile=C:/FIXApplication/lib/quickfixj-all-1.5.2

It should have been

-Dfile=C:/FIXApplication/lib/quickfixj-all-1.5.2.jar

Perhaps you can make this change, try again and see if it works.

Raghuram
  • 51,854
  • 11
  • 110
  • 122
  • The best way to known if it's there is to directly check your local maven repository for the proper file. Not only the folder, but also the contents. – Carlos Tasada Apr 24 '12 at 12:33