我怎样才能得到的构建目标在蚂蚁列表? [英] How can I get a list of build targets in Ant?

查看:102
本文介绍了我怎样才能得到的构建目标在蚂蚁列表?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的codeBase的有别人写的很长 build.properties 文件。我想看到的可用内置的目标,而无需通过文件手动搜索。蚂蚁是否有一个命令 - 这其实有点像蚂蚁节目的目标 - 这将使它列出构建文件中的所有目标。

My codebase has a long build.properties file written by someone else. I want to see the available built targets without having to search through the file manually. Does ant have a command for this - something like ant show-targets - that will make it list all the targets in the build file?

推荐答案

-p -projecthelp 选项也正是这一点,所以你可以只是尝试:

The -p or -projecthelp option does exactly this, so you can just try:

ant -p build.xml

从蚂蚁的命令行文档

-projecthelp 选项打印出的build文件的目标的列表。目标,其中包括一个说明属性被列为主要目标,那些没有说明被列为其他目标,那么默认目标上市(其他目标,只是如果没有主要目标显示,如果蚂蚁在 -verbose 或<$ C调用$ C> -debug 模式)。

The -projecthelp option prints out a list of the build file's targets. Targets that include a description attribute are listed as "Main targets", those without a description are listed as "Other targets", then the "Default" target is listed ("Other targets" are only displayed if there are no main targets, or if Ant is invoked in -verbose or -debug mode).

这篇关于我怎样才能得到的构建目标在蚂蚁列表?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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