Maven:通过相对路径向JAR添加依赖项我有一个专有的JAR,我想将它作为一个依赖项添加到我的pom中。但我不想把它添加到存储库中。原因是我想要我常用的maven命令,例如mvn compile等从盒子里拿出来工作。(不要求开发人员自己将其添加到某个存储库中)。我希望JAR位于源代码管理中的一个3 rdparty lib中,并通过相对路径链接到它。这能办到吗?多么,怎样?
3 回答
HUH函数
TA贡献1836条经验 获得超4个赞
system${basedir}
<dependency>
<artifactId>..</artifactId>
<groupId>..</groupId>
<scope>system</scope>
<systemPath>${basedir}/lib/dependency.jar</systemPath></dependency>添加回答
举报
0/150
提交
取消
