java - Managing dependencies in a Maven Project -


i have 2 jars supposed imported maven project. followed tutorial (click here) , imported jars maven project. basically, executed code in terminal: mvn install:install-file -dfile=myfile.jar -dgroupid=mygroup -dartifactid=com.mygroup.project -dversion=1.0 -dpackaging=jar -dlocalrepositorypath=lib -dcreatechecksum=true , imported library maven project.

all works fine. however, jars importing supposed have few dependencies themselves. understand, maven handles internal dependencies automatically. have list of dependencies (with group id, artefact id , version) don't understand write those. in folder 1.0 of library, there file called myjar-1.0.pom. tried writing dependencies there of no use.

could tell me way of manually telling maven load few dependencies?

i tried specifying these dependencies in main pom.xml results in errors - saying repo-url/dependency/file.pom not found. guess needs mentioned in internal dependency - can't figure out way of manually defining them. need create pom.xml within libraries, or there missing out?

you can this:

  1. write pom jar, , declare dependencies in pom.
  2. user mvn install:install-file -dfile=path-to-your-artifact-jar -dpomfile=path-to-pom install jar.

link: http://maven.apache.org/plugins/maven-install-plugin/examples/custom-pom-installation.html


Comments

Popular posts from this blog

javascript - DIV "hiding" when changing dropdown value -

Does Firefox offer AppleScript support to get URL of windows? -

android - How to install packaged app on Firefox for mobile? -