Maven程序集插件并将系统依赖项添加到类路径 [英] Maven assembly plugin and adding system dependencies to the classpath

查看:66
本文介绍了Maven程序集插件并将系统依赖项添加到类路径的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一些依赖关系,我需要自己提供.罐子位于资源目​​录中.在我的pom中,它们的作用域为系统,并且包含了它们的路径.但是,当我使用Assembly插件整理内容并使用

I have some dependencies which I am providing myself. The jars are in the resources directory. In my pom they are scoped as system and I include the path to them. However, when I jar things up using the assembly plugin and use

<addClasspath>true</addClasspath>

它不添加系统jar的路径.如何使它们自动包含在内?

It doesn't add the path of the system jars. How can I get them to be included automatically?

谢谢

推荐答案

是的,这就是使用system范围是不好的做法的原因.看看此先前的答案(还有这个)来解决.

Yeah, and that's why using system scope is a bad practice. Have a look at this previous answer (and also this one) for a solution.

这篇关于Maven程序集插件并将系统依赖项添加到类路径的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆