Maven: add a dependency to a jar by relative path

后端 未结 9 1005
半阙折子戏
半阙折子戏 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:09

    I've previously written about a pattern for doing this.

    It is very similar to the solution proposed by Pascal, though it moves all such dependencies into a dedicated repository module so that you don't have to repeat it everywhere the dependency is used if it is a multi-module build.

提交回复
热议问题