Skip to content

Notes

ant-dev

An alias to run Ant from a different build file that includes additional developer targets.

The file imports the build.xml file in the current directory.

dev.properties

Show available Ant properties.

dev.ant-graph

Create a dependency graph of targets. Uses Ant-Grand.

import versus include

import include


Imported targets are available in two versions: without prefix, or with the included project name as prefix. Included targets are only available with prefix. depend attribute targets are unchanged, and can be overridden. depend attribute targets are prefixed, and under control of the included project. A file can only be imported once. A file can be included multiple times, with different prefixes.

Color logger

Use the AnsiColorLogger to make the output easier to scan.

Two environment variables, to use the color logger and to specify my colors.

$ ANT_ARGS='-logger org.apache.tools.ant.listener.AnsiColorLogger'
$ ANT_OPTS=-Dant.logger.defaults=$HOME/.config/etc/.ant/ant.logger.defaults

:::: note ::: title Note :::

In Oh-my-zsh, the ant plugin sets ANT_ARGS to this value automatically. ::::