Maven POM file for installing multiple 3rd party commercial libraries

后端 未结 3 1779
星月不相逢
星月不相逢 2021-01-31 19:19

I have a bunch of projects which are dependant on a set of commercial 3rd party libraries. We currently don\'t have a company repository so I have to install the libraries in my

3条回答
  •  一整个雨季
    2021-01-31 19:46

    Just to add to the correct example provided by @eugene-kuleshov:

    1. Once you configure the maven-install-plugin with the goal install-file in your pom.xml file with multiple executions, one execution per external jar, you have to use these jars in your pom.xml as usual:

      
          org.some.group
          your-artifact
          1.0
      
      

      The maven-install-plugin only copies your external jars to your local .m2 maven repository. That's it. It doesn't automatically include these jars as maven dependencies to your project.

      It's a minor point, but sometimes easy to miss.

    2. You do not need to include any in your pom as long as you are installing the external jars to the .m2 repository (which is the default)

提交回复
热议问题