Maven: add a dependency to a jar by relative path

后端 未结 9 1008
半阙折子戏
半阙折子戏 2020-11-21 23:21

I have a proprietary jar that I want to add to my pom as a dependency.

But I don\'t want to add it to a repository. The reason is that I want my usual maven commands

9条回答
  •  再見小時候
    2020-11-22 00:21

    Basically, add this to the pom.xml:

    ...
    
    
       
           lib_id
           file://${project.basedir}/lib
       
    
    
    ...
    
    
      ...
      
          com.mylibrary
          mylibraryname
          1.0.0
      
      ...
    
    

提交回复
热议问题