Ant目标依赖树查看器 [英] Ant target dependency tree viewer

查看:168
本文介绍了Ant目标依赖树查看器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有一个软件(或eclipse插件),给定一个目标,可以让我以目标依赖关系的形式查看树?



树不需要是图形化的,可以是基于文本的 - 只是一个工具,可以帮助我遍历某人的网络的ant文件来调试它们。 >

不需要是Eclipse插件。但是,当一个节点被点击时,这个目标的源将会抛出一个编辑器,这样很好。

解决方案

在Eclipse中的href =https://stackoverflow.com/questions/3039933/ant-debugging-in-eclipse> ant调试。



基于关于 Apache的ANT手册,您可以从 -projecthelp 选项。这可能会更加困难,因为各种目标可能具有交叉依赖关系,因此根本无法将层次结构表示为一个树。



您可以修改构建.xml来检测环境变量,例如NO_PRINT在每个项目目标中进行测试,如果找到,只打印出项目名称,没有其他的。该项目的依赖将仍然保留,并允许ANT走树,并产生将被触动的不同目标的打印输出。


IS there a piece of software (or an eclipse plug-in) which,

given a target, would allow me to view the target dependency as a tree?

The tree does not need to be graphical, could be text based - just a tool that would help me traverse thro someone's mesh of ant files to debug them.

Does not need to be an Eclipse plug-in. However, would be nice when a node is clicked would throw the source of that target onto an editor.

解决方案

Similar to question ant debugging in Eclipse.

Based on Apache's ANT manual, you can start with the -projecthelp option. It might be more difficult after that because the various targets may have cross-dependencies and thus be impossible to represent the hierarchy as a tree at all.

You could modify the build.xml to detect an environment variable, e.g. NO_PRINT which is tested in each project target and if found, only print out the project name and nothing else. The depencies for the project would remain and allow ANT to walk the tree and produce a printout of the different targets that would get touched.

这篇关于Ant目标依赖树查看器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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