Eclipse构建路径自动占用内部目录的所有JAR [英] Eclipse buildpath automatically taking all JARs of a internal directory

查看:146
本文介绍了Eclipse构建路径自动占用内部目录的所有JAR的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何配置我的项目构建路径以将一组.jar文件位于自动包含在构建路径中的同一目录中?
意思是将新的.jar文件添加到此目录(并刷新项目)更新buildpath?
Rem:我不是在Webapp中工作,而是在独立的Java应用程序中。我知道在动态Web项目中可以将所有位于WEB-INF / lib中的.jars包含在构建路径中。是否可以做同样的包括但是在独立的应用程序?

How do I configure my project buildpath to have a set of .jar files located in the same directory automatically included in the buildpath ? Meaning that adding a new .jar file to this directory (and refreshing the project) updates the buildpath ? Rem : I am not working in a Webapp but in a standalone Java app. I know that it is possible in a Dynamic Web Project to have all the .jars located in WEB-INF/lib to be included in the build path. Is it possible to do kind of the same include but in standalone app ?

我正在使用Eclipse 3.4

I am using Eclipse 3.4

推荐答案

AFAIK,没有正常的方法。

AFAIK, there's no normal way to do this.

如果你真的想要,有一点黑客。
Eclipse .classpath文件是一个非常简单的XML。
您可以编写通过目录的脚本或蚂蚁任务,更新.classpath xml并刷新项目。

If you really want, there's a little hack. Eclipse .classpath file is a very simple XML. You can write a script or ant task that goes over a directory, updates .classpath xml and refreshes the project.

这篇关于Eclipse构建路径自动占用内部目录的所有JAR的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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