Apache Ant Changelog

What's new in Apache Ant 1.9.4

Jan 28, 2015
  • Changes that could break older environments:
  • the prefixValues attribute of didn't work as expected when set to false (the default). It is quite likely existing build files relied on the wrong behavior and expect Ant to resolve the value side against the properties defined in the property file itself - these build files must now explicitly set the prefixValues attribute to true. Bugzilla Report 54769
  • when matching an entry of a zip/tarfileset against a pattern a leading slash will be stripped from the entry name. Most archives don't contain paths with leading slashes anyway. This may cause include/exclude patterns that start with a / to stop matching anything. Such patterns only used to work by accident and only on platforms with multiple file system roots. Bugzilla Report 53949
  • DirectoryScanner and thus fileset/dirset will now silently drop all filesystem objects that are neither files nor directories according to java.io.File. This prevents Ant from reading named pipes which might lead to blocking or other undefined behavior. Bugzilla Report 56149
  • BuildFileTest and BaseSelectorTest have both been deprecated in favour of BuildFileRule and BaseSelectorRule respectively, and the tests that previously extended these base tests have been converted to JUnit 4 tests using the new "rule"s. Any external test that sub-classed a test in the Ant workspace, rather than BuildFileTest, will need changed to either use JUnit4's annotations, or be modified to extend BuildFileTest directly. This will not affect any tests that are being executed by Ant's junit or batchtest tasks that are not specifically testing Ant's code.
  • Fixed bugs:
  • / failed when the importing file was loaded from an URI or a jar and it imported a file from the local file system via an absolute path. Bugzilla Report 50953
  • could import the same resource twice when imported via different resource types. Bugzilla Report 55097
  • several calls to File#mkdirs could fall victim to a race condition where another thread already created the same directory. Bugzilla Report 55290
  • created '/' rather than './' for the parent directory of the given jarfile. Bugzilla Report 55049
  • 's fixlastline="true" didn't work when using certain filter readers. Bugzilla Report 54672
  • several places where resources are read from jars will now explicitly disable caching to avoid problems with reloading jars. Bugzilla Report 54473
  • AntClassloader will now ignore files that are part of the classpath but not zip files when scanning for resources. It used to throw an exception. Bugzilla Report 53964
  • caused a NullPointerException when no destdir was set. Bugzilla Report 55949
  • would still include the Main section of the fileset manifests if there was no nested manifest or manifest attribute. Bugzilla Report 54171
  • reading of compiler args has become more defensive Bugzilla Report 53754
  • without force="true" would not only fail to overwrite a read-only file as expected but also remove the existing file. Bugzilla Report 53095
  • would remove symbolic links to not-included files. It will still delete symlinks to directories that would have been followed even if they are not explicitly included. exclude-Patterns can still be used to preserve symbolic links. Bugzilla Report 53959
  • Sometimes copy-operations using NIO FileChannels fail. Ant will now try to use a Stream based copy operation as fallback when the Channel based copy fails. Bugzilla Reports 53102 and 54397
  • Javadoc.postProcessGeneratedJavadocs() fails for Classes that extend Javadoc Bugzilla Report 56047
  • TarInputStream will now read archives created by tar implementations that encode big numbers by not adding a trailing NUL.
  • the isExists() method of URLResource returned false positives for HTTP and FTP URLs.
  • Other changes:
  • initial support for Java 1.9
  • can optionally pass System.in to the remote process Bugzilla Report 55393
  • now supports capturing error output of the executed process and setting a property from the return code. Bugzilla Report 48478
  • now has an option to fail if javadoc issues warnings. Bugzilla Report 55015
  • has a new outputencoding attribute. Bugzilla Report 39541
  • changes to JUnitTestRunner and PlainJUnitResultFormatter to make OutOfMemoryErrors less likely. Bugzilla Report 45536
  • changes to DOMElementWriter to make OutOfMemoryErrors less likely. Bugzilla Report 54147
  • has a new attribute binaryOutput that prevents Ant from splitting the output into lines. This prevents binary output from being corrupted but may lead to error and normal output being mixed up. Bugzilla Report 55667 Bugzilla Report 56156
  • the nested elements of now have an optional inputEncoding attribute that can be used to specify the encoding of files read that don't use the platform's default encoding. Bugzilla Report 56258
  • The task now explicitly accepts and supports the gzip content encoding. Bugzilla Report 49453
  • A new resourcecollection type acts like a union of s and s that share the same configuration but have different base directories. Bugzilla Report 48621
  • has a quiet attribute that makes the task log errors only when enabled. GitHub Pull Request #1
  • has now a threads attribute allowing to run the tests in several threads. Bugzilla Report 55925
  • addition of a new ProcessUtil class providing the process id of the current process
  • changes to allow to run the JUnit testcases of Ant in parallel, by making them use unique temporary directories

New in Apache Ant 1.9.3 (Dec 30, 2013)

  • Fixed bugs:
  • swallowed the status code of nested tasks.
  • a race condition could make tasks of parallel builds to interfere with each other.
  • 's mailport still didn't work properly when using smtps.
  • using attributes belonging to the if and unless namespaces made macrodef fail.
  • Ant 1.8 exec task changes have slowed exec to a crawl
  • Apt is not available under JDK 1.8
  • Other changes:
  • Documentation fix for if/unless attributes. PR 55359.
  • tar entries with long link names are now handled the same way as entries with long names.
  • Addition of 'skipNonTests' attribute to and tasks to allow the tasks to skip classes that don't contain tests.
  • now supports a nested to specify filters.
  • 's params can now be typed.
  • build of Mac OS X pkg installer

New in Apache Ant 1.9.1 (May 24, 2013)

  • new if and unless XML namespaces available on all tasks and nested elements
  • Zip64 extensions are disabled by default
  • Loading of external dependencies fixed in JUnit tasks
  • JUnitreport default stylesheets now compatible with JDK 1.7
  • Recommending to upgrade to jsch 0.1.50 for users of the ssh/scp tasks under Java 1.7
  • Other fixes and improvements documented in WHATSNEW

New in Apache Ant 1.8.4 (May 25, 2012)

  • This is a security bugfix release that fixes a potential denial of service attack vector in the bzip2 task.

New in Apache Ant 1.8.2 (Dec 28, 2010)

  • Performance improvements in directory scanning.
  • The XSLT task honors the classpath again (bugrep 49271).
  • The distinction between core tasks and optional tasks is abolished.
  • Numerous bugfixes and improvements as documented in Bugzilla and in WHATSNEW.

New in Apache Ant 1.7.1 (Aug 6, 2009)

  • The main release focus is on fixing bugs and improving performance.
  • Java 6 support has been enhanced, and JavaFX is supported by the script task.