The buildlist task is used to obtain a list of files (usually build.xml files) sorted by Ivy dependency information from small to large, or vice versa (after 1.2)
This task is particularly effective when building related project collections in conjunction with subant to ensure that dependencies are built before other modules that depend on it.
When the ivy.xml of the module you want to sort does not contain the revision number, the Rev attribute defined on the dependency will not be used.
When you want to sort the module Ivy.xml contains the revision number, the revision number will be used. If the revision number and dependency description do not match, the warning log is logged and the module is considered to be a different module.
From the 1.3 release, the root attribute can also be used to select only the modules that depend (either directly or indirectly) on the root module in all the modules found. Can be used with the Excluderoot property and will exclude root from the list when set to True.
From the 1.4 version, the leaf attribute can also be used to select only the modules that rely on the leaf module (either directly or indirectly) in all the modules found. Can be used in conjunction with the Excludeleaf property, which excludes the leaf itself from the list when set to True.
From version 1.4, the Ivy.sorted.modules property is set in Ant after the task executes, and the value is a comma-delimited list of sorted modules. This can be used for debugging or reporting.
From version 2.0, the root and leaf properties can be separate lists of modules used as root. These modules and all of their modules will be included in the build list.
From the 2.0 release, the default all loop-dependent modules will be grouped so that any dependencies in any module in the loop appear in front of the module in the loop. If there is a dependent path between modules A and B (but not a dependent path from B to a), B will appear before a, even if a is contained in a loop for the collection of modules to be sorted.
From the 2.0 release, when you specify the roo and leaf modules you can limit the result list to the direct dependencies of the root module or the leaf module directly.
From the 2.0 release, you can specify a restartfrom module. Unlike root or leaf, you can get a list of files that start with the Restartfrom module, followed by all the modules that should be in the back if this parameter is not set (even if there is no dependency between the Restartfrom and the rear modules)
Property |
Describe |
Requirements |
Reference |
The reference of the path to set The path reference to set |
Yes |
Ivyfilepath |
The relative path from files to corresponding Ivy files The relative path from the file to the corresponding Ivy file |
No. Default is ${ivy.buildlist.ivyfilepath} |
Root |
Since 2.0 the names of the modules which should be considered as the root of the buildlist. The module name (which can be multiple) from 2.0 is considered to be the root of the build list Since 1.3 is limited to only one module name before 2.0. Limited to only one module name from 1.3 before 2.0 |
No. Default does not have root (all modules will be used in the build list) |
Excluderoot |
Since 1.3 True if the root defined should is excluded from the list True from 1.3 If you need to exclude the defined root from the list |
No. Default is False |
Leaf |
Since 2.0 the names of the modules which should be considered as the leaf of the buildlist. From 2.0 module names (which can be multiple) are considered to be the leaf of the build list Since 1.4.1 is limited to only one module name before 2.0. Since 1.4.1 is limited to only one module name before 2.0 |
No. No leaf by default (all modules will be used in the build list) |
Onlydirectdep |
Since 2.0 true if the Resulting list should is restricted to direct dependencies of root modules or modules this directly depends on the leaf mo Dules. This are ignored when neither root neither the leaf is filled. True from 2.0 If the result list is limited to the direct dependency of the root module or directly depends on the leaf module. This property is ignored when root and leaf are not set |
No. Default is False |
Delimiter |
Since 2.0 delimiter to use when specifying multiple module, names in the root and leaf properties. Separator used in root and leaf properties when multiple module names are specified from 2.0 |
No. The default is a comma (,). |
Excludeleaf |
Since 1.4.1 True if the leaf defined should is excluded from the list From 1.4.1 true if you need to exclude the defined leaf from the list |
No. Default is False |
Haltonerror |
True to halt the "build" Invalid Ivy file is encountered, false to continue True terminates build when an invalid Ivy file is encountered, False continues |
No. The default is True |
skipbuildwithoutivy |
deprecated, use Onmissingdescriptor instead. True to skip files of the fileset with no corresponding ivy file, False otherwise. If false the file with no corresponding ivy file'll be considered as independent of the ' the other ' and put at the beginning O f The built filelist. The declares that it is not supported for continued use, please use Onmissingdescripto. |
no. The default is False |
Onmissingdescriptor |
Since 2.0 specify the action to take when no module descriptor the found of the ' file is ' for a file of. Possible values are: Specify a processing action from 2.0 when a file in a file collection cannot locate a module description file: Head Put in the head of the built filelist. Tail Put in the tail of the built filelist. Skip Skip the file, which won ' t is put on the build filelist. Warn Warn and put in the head of the build filelist. Fail Halt the build with a failure. |
No. Defaults to ' head ' |
Reverse |
True to obtain the "list in" reverse order, i.e. from the most dependent to the least one True to get a list of flashback permutations. For example, from maximum dependency to minimum |
No. Default is False |
Restartfrom |
Since 2.0 the name of the module which should is considered as the starting point in the buildlist. This is the allows for the "build" to is started at any point in the dependency chain. The name of the module that is considered to be the starting point of the build list from 2.0. This allows the build to start from any node in the dependency chain. |
No. The default is no restart point (all modules will be used in the build list). |
Settingsref |
Since 2.0 A reference to the Ivy settings of that must is used by this task From 2.0 onwards must be a reference to the Ivy set used by this task. |
No, use ' ivy.instance ' by default. |