在WAR文件中排除常春藤依赖 [英] Exclude Ivy Dependencies in WAR File

查看:89
本文介绍了在WAR文件中排除常春藤依赖的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Eclipse和Ivy插件IvyDE.

I use Eclipse and the Ivy plugin IvyDE.

我目前通过使用Eclipse的WAR功能导出来创建WAR文件.我不使用ANT构建文件-我让Eclipse处理.

I currently create a WAR file by using Eclipse's export to WAR functionality. I don't use an ANT build file - I let Eclipse handle that.

当我导出到war时,ivy.xml文件中的所有依赖项都将复制到war文件的bin目录中.我想排除其中一个(或多个).我怎么做?

When I export to war, all the dependencies in the ivy.xml file get copied to the war file's bin directory. I want to exclude one (or more) of them. How do I do that?

最简单的方法是什么?如果可能的话,我想避免创建自己的ANT构建文件,而是继续使用Eclipse的导出工具和IvyDE插件.

What't the simplest way to accomplish this? If possible, I would like to avoid creating my own ANT build files and continue to use Eclipse's export tool and the IvyDE plugin.

推荐答案

右键单击项目的ivy.xml,然后选择添加常春藤库".

Right click on your project's ivy.xml, and choose "Add ivy library".

在主选项卡中是构建配置的自定义设置,看起来您可以选择所需的conf(即,将其设置为runtime).我不喜欢使用Ant,因此从未尝试过.我想这会满足您的要求.

In the main tab are customization settings for the build configs, and it looks as though you can choose the conf you desire (i.e. set it to runtime). I war using Ant, so I've never tried it. I presume this will accomplish what you desire.

这篇关于在WAR文件中排除常春藤依赖的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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