I am trying to add external JAR file tigase-muc in a maven based project tigase-server in eclipse IDE.
I have tried following method
mvn install:install-file -Dfile=<path-to-file> -DgroupId=<group-id> \
-DartifactId=<artifact-id> -Dversion=<version> -Dpackaging=<packaging>
[INFO] Scanning for projects...
[INFO]
[INFO] Building Tigase XMPP Server 5.1.0 5.2.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-install-plugin:2.3:install-file (default-cli) @ tigase-server ---
[INFO] Installing /home/haider/Downloads/tigase-muc-2.2.0.jar to /
home/haider/.m2/repository/tigase/tigase-muc/2.2.0/tigase-muc-2.2.0.jar
[INFO] --------------
[INFO] BUILD SUCCESS
[INFO] -------------
[INFO] Total time: 0.791s
[INFO] Finished at: Mon Aug 05 18:06:48 PKT 2013
[INFO] Finished at: Mon Aug 05 18:06:48 PKT 2013
[INFO] ----------------------
From above BUILD SUCCESS message i assume that JAR file is correctly added , but when i add following dependency in POM file
<dependency>
<groupId>tigase</groupId>
<artifactId>tigase-xmltools</artifactId>
<version>3.3.6</version>
<scope>compile</scope>
</dependency>
It give me following error Missing artifact tigase:tigase-muc. This message clearly indicate that it didn't get the JAR file that i am referring in dependency
You Contribution will be highly appreciated THANKS
It looks like it installs the Jar like this: [INFO] Installing /home/haider/Downloads/tigase-muc-2.2.0.jar to / home/haider/.m2/repository/tigase/tigase-muc/2.2.0/tigase-muc-2.2.0.jar
As maven works, its group id is resolved to be ''tigase'', artifactId is ''tigase-muc'', version is ''2.2.0'' So this is right.
Now, I've took a look on tigase:tigase-xmltools:3.3.6 available here
It doesn't define any dependency at all.
So it looks like this would happen even if you don't specify this dependency :)
I would suggest you to run mvn dependency:tree
to see where does this dependency comes from
Hope this helps
A more complete error message would help narrow down what's gone wrong. The artifact you installed should be resolvable via the following dependency:
<dependency>
<groupId>tigase</groupId>
<artifactId>tigase-muc</artifactId>
<version>2.2.0</version>
<type>jar</type>
<scope>compile</scope>
</dependency>
You're reference tigase-xmltools which I'm assuming has a dependency on tigase-muc.
My guess is tigase-xmltools might have dependency on the actual pom of tigase-muc, which you don't have despite having the jar. Seeing the full error message and the pom of tigase-xmltools.
Installing the file with -DgeneratePom=true might help.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With