Configuration

In order to work as you want, ivy need some configuration. Actually, ivy can work with no configuration at all, see the default configuration documentation for details about that. But ivy is able
to work in very different contexts. You just have to configure it properly.

Configuration is done through an xml file, usually called ivyconf.xml. To configure ivy from ant, you just have to call the configure task and pass it the path to your configuration file (see configure task documentation for details).

Here is an example of configuration file :

<ivyconf>
        <properties file="${ivy.conf.dir}/ivyconf-file.properties" />
        <conf defaultCache="${cache.dir}" defaultResolver="ibiblio" checkUpToDate="false" />
        <resolvers>
                <ibiblio name="ibiblio" />
                <filesystem name="internal">
                        <ivy pattern="${repository.dir}/[module]/ivy-[revision].xml" />
                        <artifact pattern="${repository.dir}/[module]/[artifact]-[revision].[ext]" />
                </filesystem>
        </resolvers>
        <modules>
                <module organisation="jayasoft" name=".*" resolver="internal" />
        </modules>
</ivyconf>



Mainly, the configuration enables to configure the default cache directory used by ivy and the dependency resolvers that it will use to resolve dependencies.
Note: To work, this configuration file needs a property file named ivyconf-file.properties in the same directory as the configuration file, with ivy variables you want in it.

Some useful variables are available in ivyconf files:

since 1.4 Note that all java system properties are available as ivy variables in your configuration file.

Configuration file structure

The configuration file is structured in some parts and left other open. Indeed each resolver has its own
structure, thus it's not the configuration file itself which define the structure for the resolvers.

ivyconf
    property
    properties
    conf
    include
    classpath
    typedef
    latest-strategies
    version-matchers
    triggers
    parsers
    conflict-managers
    outputters
    namespaces
        namespace
            rule
                fromsystem
                    src
                    dest
                tosystem
                    src
                    dest
    macrodef
        attribute
        any resolver
    resolvers
        any resolver
    modules
        module
    statuses
        status

ivyconf

Tag: ivyconf

Root tag of any ivyconf file.

Child elements

Element Description Cardinality
property set an ivy variable 0..n
properties loads a properties file as ivy variables 0..n
conf configures ivy with some defaults 0..1
include includes another ivyconf file 0..n
classpath add a location in the classpath used to load plugins 0..n
typedef defines new types in ivy 0..n
latest-strategies defines latest strategies 0..1
parsers defines module descriptor parsers 0..1
version-matchers defines new version matchers 0..1
triggers register triggers on ivy events 0..1
namespaces defines new namespaces 0..1
macrodef defines a new macro resolver 0..n
resolvers defines dependency resolvers 0..1
conflict-managers defines conflicts managers 0..1
modules defines rules between modules and dependency resolvers 0..1
outputters defines the list of available report outputters 0..1
statuses defines the list of available statuses 0..1

property

Tag: property

Defines an ivy variable. since 1.3

The optional override attribute enables to avoid overriding the previous value of the varable, which makes the definition behave like ant properties, which is particularly useful to define default values (values which are used only if they haven't been defined yet).

Attributes

Attribute Description Required
name the name of the variable to define Yes
value the new value the variable must take Yes
override true if the previous value (if any) of the variable should overriden, false otherwise No, defaults to true

Examples

<property name="myvar" value="myvalue"/>

Sets the variable myvar to the value myvalue.


<property name="myvar" value="myvalue" override="false"/>

Sets the variable myvar to the value myvalue only if myvar has not been set yet.

properties

Tag: properties

Loads a properties file into ivy variables. See variables chapter above for details about ivy variables.

Attributes

AttributeDescriptionRequired
filea path to a properties file to load Yes
overrideindicates if the variable found in the properties file should override their previous value, if any since 1.3 No, defaults to true

conf

Tag: conf

Configures some important ivy info: default cache, default resolver, ...

Note that this is not related at all with conf found in ivy files. This tag is only used to setup ivy.

Default cache is used whenever a cache is not provided. It usually points to a directory in your filesystem. This should not point to a directory used as a repository!

Default resolver is used whenever nothing elese is configured in the modules section of the configuration file. It should give the name of a dependency resolver defined in the resolvers section of the configuration file.

Default latest strategy and conflict manager can also be configured here.

validate indicates if ivy files should generally be validate against xsd or not. This setting is only a default value, and can be overriden :
1) in ant tasks
2) in resolvers
So if there is a setting in the resolver, it always win against all other settings.

checkUpToDate indicates to ivy if it must check date of artifacts before retrieving them (i.e. copying them from
cache to another place in your filesystem). Usually it is a good thing to check date to avoid unnecessary copy, even if it's most of the time a local copy.

cacheIvyPattern and cacheArtifactPattern are used to configure the way ivy stores ivy files and artifacts in the cache. Usually you do not have to change this, unless you want to use the cache directly from another tool, which is not recommended.

Attributes

Attribute Description Required
defaultCache a path to a directory to use as default cache No, defaults to .ivy/cache in user home
defaultResolver the name of the default resolver to use No, but all modules should be configured in the modules section if not provided
defaultLatestStrategy the name of the default latest strategy to use No, defaults to latest-revision
defaultConflictManager the name of the default conflict manager to use No, defaults to latest-revision
defaultBranch the default branch to use for all modules, except if they have a module specific branch setting. since 1.4 No, defaults to no default branch
circularDependencyStrategy the name of the circular dependency strategy to use since 1.4 No, defaults to warn
validate Indicates if ivy files should be validated against ivy.xsd or not. No, defaults to true
checkUpToDate Indicates if date should be checked before retrieving artifacts from cache No, defaults to true
cacheIvyPattern a pattern to indicate where ivy files should be put in cache No, defaults to [organisation]/[module]/ivy-[revision].xml
cacheArtifactPattern a pattern to indicate where artifact files should be put in cache No, defaults to [organisation]/[module]/[type]s/[artifact]-[revision].[ext]
useRemoteConfig true to configure ivyrep and ibiblio resolver from a remote configuration file (updated with changes in those repository structure if any) (since 1.2) No, defaults to false

include

Tag: include

Includes another ivyconf file as if it were part of this one. since 1.3

The included ivyconf file has to be a complete well formed ivyconf file, i.e. it does have to include the <ivyconf> tag.

Attributes

Attribute Description Required
file a path to the ivyconf file to include Yes

Examples

<ivyconf>
  <property name="myrepository" value="path/to/my/real/rep"/>
  <conf defaultResolver="default"/>
  <include file="path/to/ivyconf-default.xml"/>
</ivyconf>

with ivyconf-default.xml:

<ivyconf>
  <property name="myrepository" value="path/to/rep" overwrite="false"/>
  <resolvers>
    <ivyrep name="default" ivyroot="${myrepository}"/>
  </resolvers>
</ivyconf>

The included ivyconf defines a resolver named default, which is an ivyrep resolver, with its root configured as being the value of myrepository variable. This variable is given the value path/to/rep in the included file, but because the attribute overwrite is set to false, it will not overide the value given in the main ivyconf including this one, so the value used for myrepository will be path/to/my/real/rep.


<ivyconf>
  <include file="ivyconf-macro.xml"/>
  <resolvers>
    <mymacro name="includeworks" mymainrep="included/myrep" mysecondrep="included/secondrep"/>
  </resolvers>
</ivyconf>

with ivyconf-macro.xml being the ivyconf example given on the macrodef documentation page.
This let reusing macro resolver easy.

classpath

Tag: classpath

Includes a jar in the classpath used to load plugins. since 1.4

This let you add ivy plugins without relying on ant classpath for instance, easing therefore the use of ivy in multiple execution environment (ant, standalone, IDE plugins, ...).

Attributes

Attribute Description Required
url the url of a jar to add to the classpath Yes, unless file is specified
file a jar to add to the classpath Yes, unless url is specified

Examples

<ivyconf>
  <classpath file="${ivy.conf.dir}/custom-resolver.jar"/>
  <typedef name="custom" classname="fr.jayasoft.ivy.resolver.CustomResolver"/>
  <resolvers>
    <custom name="custom"/>
  </resolvers>
</ivyconf>

Adds custom-resolver.jar found in the same directory as the ivyconf.xml file itself to the classpath, then define a custom resolver and use it.


<ivyconf>
  <classpath url="http://www.myserver.com/ivy/custom-resolver.jar"/>
  <typedef name="custom" classname="fr.jayasoft.ivy.resolver.CustomResolver"/>
  <resolvers>
    <custom name="custom"/>
  </resolvers>
</ivyconf>

Same as above, but find the jar on a web server.

typedef

Tag: typedef

Defines a new type in ivy. Useful to define new dependency resolvers, in particular, but also latest strategies. See how to write and plug your own dependency resolver for details.

Attributes

AttributeDescriptionRequired
namethe name of the type to define. This name is then used as an xml tag. Yes
classnamethe fully qualified class name of the type to define. Yes

latest-strategies

Tag: latest-strategies

Defines a list of latest strategies usable in ivy. Each latest strategy is identified by its name, given as an attribute.
The child tag used for the latest strategy must be equal to a name of a latest strategy type (usually added with the typedef tag).

The latest strategies which are always included in ivy (and do not require anything in the configuration file) are:

  • latest-time
  • compares the revisions date to know which is the latest. While this is often a good
    strategy in terms of pertinence, it has the drawback to be costful to compute with distant repositories. If you use ivyrep,
    for example, ivy has to ask the http server what is the date of each ivy file before knowing which is the latest.

  • latest-revision
  • compares the revisions as string, using an algorithm close to the one used in the php version_compare function.
    This algorithm takes into account special meaning of some text. For instance, with this strategy, 1.0-dev1 is considered
    before 1.0-alpha1, which in turn is before 1.0-rc1, which is before 1.0, which is before 1.0.1.

  • latest-lexico
  • compares the revisions as string, using lexicographic order (the one used by java string comparison).

Child elements

Element Description Cardinality
any latest strategy adds a latest strategy to the list of available strategies 0..n

latest-revision

since 1.4 The latest-revision can now be configured to handle more words with special meanings than the one defined in php version_compare function.

Here is an example of how you can do so:

<latest-strategies>
  <latest-revision name="mylatest-revision">
    <specialMeaning name="PRE" value="-2"/>
    <specialMeaning name="QA" value="4"/>
    <specialMeaning name="PROD" value="5"/>
  </latest-revision>
</latest-strategies>

Knowing that the default special meaning words are the following:

    <specialMeaning name="dev" value="-1"/>
    <specialMeaning name="rc" value="1"/>
    <specialMeaning name="final" value="2"/>

You can even get rid or redefine the default special meanings by setting usedefaultspecialmeanings="false" on the latest-revision tag.
Example:

<latest-strategies>
  <latest-revision name="mylatest-revision" usedefaultspecialmeanings="false">
    <specialMeaning name="pre" value="-2"/>
    <specialMeaning name="m" value="1"/>
    <specialMeaning name="rc" value="2"/>
    <specialMeaning name="prod" value="3"/>
  </latest-revision>
</latest-strategies>

parsers

Tag: parsers

Defines a list of module descriptor parsers usable in ivy. Each parser defines which resources (which descriptor file) it accepts.
The child tag used for the parser must be equal to a name of a parser type (added with the typedef tag).

Note that when looking for a parser, ivy queries the parsers list in the reverse order. So the last parser in the list will be queried first. Consequently, if the last parser accepts all resources, the other parsers will never have a chance to parse the resource.

Two parsers are available by default and thus do not need to be declared in this section:

  • ivy file parser
  • this is the parser used for ivy xml files. This parser is used for resources that aren't accepted by any other parser.

  • pom parser
  • this parser is able to parse maven2 pom files

Child elements

Element Description Cardinality
any module descriptor parser adds a module descriptor parser to the list of available parsers 0..n

namespaces

Tag: namespaces

Namespaces are an advanced feature of Ivy which let you use resolvers in which module names and organisations are not consistent between each other.

For instance, if you want to use maven2 repository and ivyrep collectively, you will face some naming issues. For example all apache commons projects are declared to be part of the organisation apache in ivyrep whereas in maven2 ibiblio repository, they are declared to be part of the organisation of the same name of the module.

So if you try to use both maven2 and ivyrep repositories, you will face some issues like:

How do I declare a dependency on commons-lang ?
I have an error while trying to resolve module xxx. It says that it depends on [commons-httpclient commons-httpclient] ant that it isn't available.
...

Ivy has an answer to give to this kind of troubles, and this answer is called namespaces. In short, you can affect a namespace to each dependency resolver in Ivy, and each namespace defines rules to convert names from the system namespace to the defined namespace itself, and vice versa.

This very powerful feature is thoroughly used in the build your own repository tutorial, and this is a good place to have examples of what can be done with namespaces.

Child elements

Element Description Cardinality
namespace defines a new namespace 0..n

namespace

Tag: namespace

Defines a new namespace. A namespace is identified by a name, which is used to reference the namespace in the resolvers using the namespace.

Namespaces overview is given in the namespaces documentation.

A namespace mainly consists of a list of rules, each rule defining a translation between system namespace and the defined namespace, and vice versa.

There are two main possibilities for using these rules. By default, a namespace iterate through the rules, and when it finds one that translate the given name, it returns the translated name. But the namespace can be configured to do use the list as a translator chain: in this case, all rules are applied in order, the result of the first rule translation being passed to the second, and so on.

Attributes

Attribute Description Required
name the namespace name Yes
chainrules true to indicate that namespaces rules should be chained, false otherwise No, defaults to false

Child elements

Element Description Cardinality
rule defines a new namespace rule 0..n

Example

<namespace name="test">
  <rule>
    <fromsystem>
      <src org="systemorg"/>
      <dest org="A"/>
    </fromsystem>
    <tosystem>
      <src org="A"/>
      <dest org="systemorg"/>
    </tosystem>
  </rule>
</namespace>
<namespace name="test">
  <rule>
    <fromsystem>
      <src org="systemorg2" module="system\-(.+)"/>
      <dest org="B" module="$m1"/>
    </fromsystem>
    <tosystem>
      <src org="B" module=".+"/>
      <dest org="systemorg2" module="system-$m0"/>
    </tosystem>
  </rule>
</namespace>
<namespace name="test" chainrules="true">
  <rule>
    <fromsystem>
      <src org="systemorg"/>
      <dest org="A"/>
    </fromsystem>
    <tosystem>
      <src org="A"/>
      <dest org="systemorg"/>
    </tosystem>
  </rule>
  <rule>
    <fromsystem>
      <src module="systemmod"/>
      <dest module="A"/>
    </fromsystem>
    <tosystem>
      <src module="A"/>
      <dest module="systemmod"/>
    </tosystem>
  </rule>
  <rule>
    <fromsystem>
      <src module="systemmod2"/>
      <dest module="B"/>
    </fromsystem>
    <tosystem>
      <src module="B"/>
      <dest module="systemmod2"/>
    </tosystem>
  </rule>
</namespace>

rule

Tag: rule

Defines a new namespace rule. A rule defines a translation between system namespace and the defined namespace, and vice versa.

See namespace doc for details.

Child elements

Element Description Cardinality
fromsystem defines the translation to apply from system namespace to the defined namespace 1
tosystem defines the translation to apply from the defined namespace to system namespace 1

fromsystem / tosystem

Tag: fromsystem / tosystem

Defines a one way translation rule, i.e. a translation from system namespace to the defined namespace or vice versa.

Child elements

Element Description Cardinality
src defines a source name which can be accepted 1..n
dest defines the translation to apply when a name is accepted by an src pattern 1

src

Tag: src

Defines the acceptation part of a translation rule. If a name matches this src, it will be translated using the dest part.

Attributes

Attribute Description Required
org the organisation to match as a regexp No, defaults to .*
module the module name to match as a regexp No, defaults to .*
rev the revision to match as a regexp No, defaults to .*

dest

Tag: dest

Defines the translation part of a translation rule. If a name has matched a corresponding src, it will be translated using this dest part.

The new names can contain references to groups of the matched name, using a slightly modified regexp syntax. Indeed, referenced groups can be part of either the organisation, module or revision part of the original name. So, to reference the groups, you just have to add a letter identifying the part in which the group should be selected: o for organisation, m for module, and r for revision.

For instance, $o0 matches the whole matched organisation, and $m0 the whole matched module name. $o1 matches the first group of the matched organisation.

For details about regexp and groups, see the Pattern class documentation in the jdk.

Attributes

Attribute Description Required
org the new organisation name No, defaults to $o0
module the new module name No, defaults to $m0
rev the new revision No, defaults to $r0

Examples

    <fromsystem>
      <src org="systemorg2" module="system\-(.+)"/>
      <dest org="B" module="$m1"/>
    </fromsystem>

Matches modules from systemorg2 which have a name beginning with system followed by a minus and anything else, and translate it to organisation B and module the part following system- of the original name.

macrodef

Tag: macrodef

Defines a new dependency resolver type based upon an other one. This definition is very similar to the macrodef feature of ant for defining macro tasks. since 1.3

This task eases the lot the process of creating new dependency resolver, because it avoid writing java code.

It is generally used in combination with the include feature to help reusing macro at several places.

A macro is defined by writing the resolver it is equivalent to as if it were written in the resolver place, except that you can use attributes to pass parameters to the newly defined resolver type. Attributes are defined with a name and sometimes a default value, and are used using the following syntax: @{attributename}.

Attributes

Attribute Description Required
name name of the resover type created Yes

Child elements

Element Description Cardinality
attribute defines an attribute for the macro resolver 0..n
any resolver defines the base resolver upon which this macro is defined 1

Examples

Defining a simple macro:

  <macrodef name="mymacro">
    <attribute name="mymainrep"/>
      <filesystem name="fs1">
        <ivy pattern="@{mymainrep}/[organisation]/[module]/[type]s/[artifact]-[revision].[ext]"/>
        <artifact pattern="@{mymainrep}/[organisation]/[module]/[type]s/[artifact]-[revision].[ext]"/>
      </filesystem>
  </macrodef>

Using it:

  <resolvers>
    <mymacro name="default" mymainrep="path/to/myrep"/>
  </resolvers>



A complete example:

<ivyconf>
  <macrodef name="mymacro">
    <attribute name="mymainrep"/>
    <attribute name="mysecondrep"/>
    <attribute name="myseconddirlayout" default="[organisation]/[module]/[type]s"/>
    <chain>
      <filesystem name="fs1">
        <ivy pattern="@{mymainrep}/[organisation]/[module]/[type]s/[artifact]-[revision].[ext]"/>
        <artifact pattern="@{mymainrep}/[organisation]/[module]/[type]s/[artifact]-[revision].[ext]"/>
      </filesystem>
      <filesystem name="fs2" latest="latest-time">
        <ivy pattern="@{mysecondrep}/@{myseconddirlayout}/ivy-[revision].xml"/>
        <artifact pattern="@{mysecondrep}/@{myseconddirlayout}/[artifact]-[revision].[ext]"/>
      </filesystem>
    </chain>
  </macrodef>

  <resolvers>
    <mymacro name="default" mymainrep="path/to/myrep" mysecondrep="path/to/secondrep"/>
    <mymacro name="other"
      mymainrep="path/to/myrep"
      mysecondrep="path/to/secondrep"
      myseconddirlayout="[module]/[type]s"/>
  </resolvers>
</ivyconf>

attribute

Tag: attribute

Defines a macrodef attribute. See macrodef for details.

Attributes

Attribute Description Required
name the name of the attribute Yes
default the default value of the attribute if none is specified No, by default attribute are required

resolvers

Tag: resolvers

Defines a list of dependency resolvers usable in ivy. Each dependency resolver is identified by its name, given as an attribute.

The child tag used for the dependency resolver must be equal to a name of a dependency resolver type (either built-in or added with the typedef tag).

since 1.3 Once defined, resolvers can be referenced by their name, using the following syntax:

<resolver ref="alreadydefinedresolver"/>

Note that this works only if the resolver has been already defined, and not if it is defined later in the ivyconf file.

Child elements

Element Description Cardinality
any resolver adds a resolver to the list of available resolvers 1..n

Built-in Resolvers

Ivy comes with a set of built-in dependency resolvers able to answer to the most common needs.

If you don't find the one you want here, you can also check if some one has not contributed it in the links page, or even write your own.

There are basically two types of resolver in Ivy: composite and standard resolvers. A composite resolver is a resolver which delegates the work to other resolvers. The other resolvers are standard resolvers.

Here is the list of built-in resolvers:

Name Type Description
IvyRep Standard Finds ivy files on ivyrep and artifacts on ibiblio.
IBiblio Standard Finds artifacts on ibiblio.
FileSystem Standard This very performant resolver finds ivy files and artifacts in your file system.
Url Standard Finds ivy files and artifacts in any repository accessible with urls.
Vfs Standard Finds ivy files and artifacts in any repository accessible with apache commons vfs.
ssh Standard Finds ivy files and artifacts in any repository accessible with ssh.
sftp Standard Finds ivy files and artifacts in any repository accessible with sftp.
Chain Composite Delegates the finding to a chain of sub resolvers.
Dual Composite Delegates the finding of ivy files to one resolver and of artifacts to another.

Common attributes

All resolvers of the same type share some common attributes detailed here:

Attribute Description Required Composite Standard
name the name which identify the resolver Yes Yes Yes
validate indicates if resolved ivy files should be validated against ivy xsd No, defaults to call setting Yes Yes
checkmodified Indicates if this resolver should check lastmodified date to know if an ivy file is up to date. No, defaults to ${ivy.resolver.default.check.modified} No Yes
changingPattern Indicates for which revision pattern this resolver should check lastmodified date to know if an artifact file is up to date. since 1.4 No, defaults to none Yes Yes
changingMatcher The name of the pattern matcher to use to match a revision against the configured changingPattern. since 1.4 No, defaults to exactOrRegexp Yes Yes
alwaysCheckExactRevision Indicates if this resolver should check the given revision even if it's a special one (like latest.integration). since 1.3 No, defaults to ${ivy.default.always.check.exact.revision} No Yes
namespace The name of the namespace to which this resolver belong since 1.3 No, defaults to 'system' Yes Yes
checkconsistency true to check consistency of module descriptors found by this resolver, false to avoid consistency check since 1.3 No, defaults to true No Yes
allownomd true if the absence of module descriptor (usually an ivy file) is authorised for this resolver, false to refuse modules without module descriptor since 1.4 No, defaults to true No (except dual) Yes
checksums a comma separated list of checksum algorithms to use both for publication and checking since 1.4 No, defaults to ${ivy.checksums} No Yes
latest The name of the latest strategy to use. No, defaults to 'default' Yes Yes

Examples

<resolvers>
  <filesystem name="1">
    <ivy pattern="${ivy.conf.dir}/1/[organisation]/[module]/ivys/ivy-[revision].xml"/>
    <artifact pattern="${ivy.conf.dir}/1/[organisation]/[module]/[type]s/[artifact]-[revision].[ext]"/>
  </filesystem>
  <chain name="chain1">
    <resolver ref="1"/>
    <ivyrep name="ivyrep"/>
  </chain>
  <chain name="chain2" returnFirst="true" dual="true">
    <resolver ref="1"/>
    <ibiblio name="ibiblio"/>
  </chain>
</resolvers>

Defines a filesystem resolver, named '1', which is then used in two chains, the first which seconds the filesystem resolver with an ivyrep resolver, and second which seconds the filesystem resolver with an ibiblio resolver, and which returns the first module found, and uses the whole chain to download artifacts (see corresponding resolvers documentation for details about them).

IvyRep Resolver

Tag ivyrep
Handle latest yes, at least if the repository server is apache based
Handle publish no

This resolver usually uses ivyrep to find ivy files and ibiblio to find artifacts.
However it can be configured to use other similar repositories.

Note that if no ivy file is found on ivyrep, then this resolver behaves like ibiblio resolver. Thus it's usually better to use this resolver instead of ibiblio one, which is provided mainly for compatibility reasons.

Attributes

This resolver shares the common attributes of standard resolvers.

Attribute Description Required
ivyroot the root of the ivy repository. No, defaults to ${ivy.ivyrep.default.ivy.root}
ivypattern a pattern describing the layout of the ivy repository. No, defaults to ${ivy.ivyrep.default.ivy.pattern}
artroot the root of the artifacts repository. No, defaults to ${ivy.ivyrep.default.artifact.root}
artpattern a pattern describing the layout of the artifacts repository. No, defaults to ${ivy.ivyrep.default.artifact pattern}

Examples

<ivyrep name="ivyrep" />

A default ivyrep resolver, looking for ivy files on ivyrep and artifacts on ibiblio.


<ivyrep name="ivyrep" ivyroot="http://ivyrep.mycompany.com"/>

Looks for ivy files on and ivyrep like web site located at http://ivyrep.mycompany.com.

IBiblio Resolver

Tag ibiblio
Handle latest yes, at least if the repository server is apache based
Handle publish no

This resolver usually uses ibiblio to find artifacts.

Prefer the use of ivyrep resolver which adds ivy file handling to this resolver.

since 1.3 Using the m2compatible attribute, you can benefit from maven 2 repository compatibility (convert dots in organisation in slashes, search for poms, use transitive dependencies of poms). This setting also affects the default place where the resolver look for its artifacts to point to the maven2 repository. So setting this attribute to true is sufficient to use maven 2 ibiblio repository.

since 1.4 When using the m2compatible flag, you can disable the use of poms by setting the usepoms flag to false. It is then roughly equivalent to an url resolver configured like this:

<url name="test" m2compatible="true">
  <artifact pattern="http://www.ibiblio.org/maven2/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]"/>
</url>

Attributes

This resolver shares the common attributes of standard resolvers.

Attribute Description Required
root the root of the artifacts repository. No, defaults to ${ivy.ibiblio.default.artifact.root}
pattern a pattern describing the layout of the artifacts repository. No, defaults to ${ivy.ibiblio.default.artifact.pattern}
m2compatible True if this resolver should be maven2 compatible, false otherwise since 1.3 No, defaults to false
usepoms True if this resolver should use maven poms when it is already in m2compatible mode, false otherwise since 1.4 No, defaults to true

File System resolver

Tag filesystem
Handle latest yes
Handle publish yes


This resolver uses the file system to resolve ivy files and artifacts. It presents the advantage to usually have very good performances. Moreover, it is easy to setup using basic OS file sharing mechanism.

The configuration of such a resolver is mainly done through ivy and artifact patterns, indicating where ivy files and artifacts can be found in the file system. You can indicate a list of pattern which will be checked one after the other.

since 1.3 Using the m2compatible attribute, this resolver will convert dots found in organisation in slashes like maven2 does for groupId. For instance, it will transform the organisation from 'com.company' into 'com/company' when replacing the token [organisation] in your pattern.

Attributes

This resolver shares the common attributes of standard resolvers.

Attribute Description Required
m2compatible True if this resolver should be maven2 compatible, false otherwise since 1.3 No, defaults to false
local True if this resolver should be considered local, false otherwise since 1.4. See useOrigin attribute on the resolve task for details. No, defaults to true

Child elements

Element Description Cardinality
ivy defines a pattern for ivy files, using the pattern attribute 0..n
artifact defines a pattern for artifacts, using the pattern attribute 1..n

Url Resolver

Tag url
Handle latest yes with http urls (and apache server) and with file urls, no with other urls
Handle publish no



This resolver is one of the most generic, in fact most of the previous resolvers can be obtained by a particular configuration of this one. Indeed it uses urls to find ivy files and artifacts. The urls it uses are defined through ivy and artifact children, each giving a pattern to find ivy files or artifacts.

Attributes

This resolver shares the common attributes of standard resolvers.

Attribute Description Required
m2compatible True if this resolver should be maven2 compatible, false otherwise since 1.3 No, defaults to false

Child elements

Element Description Cardinality
ivy defines a pattern for ivy files, using the pattern attribute 0..n
artifact defines a pattern for artifacts, using the pattern attribute 1..n

Example

<url name="two-patterns-example">
  <ivy pattern="http://ivyrep.mycompany.com/[module]/[revision]/ivy-[revision].xml" />
  <artifact pattern="http://ivyrep.mycompany.com/[module]/[revision]/[artifact]-[revision].[ext]" />
  <artifact pattern="http://ivyrep.mycompany.com/[module]/[revision]/[artifact].[ext]" />
</url>

Looks for ivy files in one place and for artifacts in two places: with or without revision in name (revision being already in the directory structure).

Chain Resolver

Tag chain
Handle latest depends on sub resolvers
Handle publish delegates to first sub resolver in chain

This resolver is only a container of a chain of other resolvers. The sub resolvers can be any resolver, including a chain. An attribute enable to indicate if the chain must be iterated after the first found or not (at least when asking for a latest revision). If the chain is iterated, then it's the latest among the ones found that is returned. If the chain is not iterated, then it's the first found which is returned.

Attributes

This resolver shares the common attributes of composite resolvers.

Attribute Description Required
returnFirst true if the first found should be returned. No, defaults to false
dual true if the chain should behave like a dual chain. since 1.3 No, defaults to false

Child elements

Element Description Cardinality
any resolver a sub resolver to use 1..n

Examples

<chain name="test">
  <filesystem name="1">
    <ivy pattern="${ivy.conf.dir}/1/[organisation]/[module]/ivys/ivy-[revision].xml"/>
    <artifact pattern="${ivy.conf.dir}/1/[organisation]/[module]/[type]s/[artifact]-[revision].[ext]"/>
  </filesystem>
  <ivyrep name="2"/>
</chain>

Both a filesystem and ivyrep will be used to look for ivy files. If a dynamic revision is required, then both the filesystem and ivyrep will be queried to find the most recent revision among the two resolvers. Once the most recent revision is found in one resolver, it's the same resolver which will be used to download artifacts.


<chain name="test" returnFirst="true">
  <filesystem name="1">
    <ivy pattern="${ivy.conf.dir}/1/[organisation]/[module]/ivys/ivy-[revision].xml"/>
    <artifact pattern="${ivy.conf.dir}/1/[organisation]/[module]/[type]s/[artifact]-[revision].[ext]"/>
  </filesystem>
  <ivyrep name="2"/>
</chain>

Same as before, except that if a revision is found in the filesystem then ivyrep will not be queried: its the filesystem which will be used for both the ivy file and the artifacts.


<chain name="test" dual="true">
  <filesystem name="1">
    <ivy pattern="${ivy.conf.dir}/1/[organisation]/[module]/ivys/ivy-[revision].xml"/>
    <artifact pattern="${ivy.conf.dir}/1/[organisation]/[module]/[type]s/[artifact]-[revision].[ext]"/>
  </filesystem>
  <ivyrep name="2"/>
</chain>

Same as first example, except that once a module is found by either filesystem or ivyrep, then it's the whole chain which will be queried to download the artifacts. So in this case ivy file and artifacts may be split across the two resolvers for the same module.

Dual resolver

Tagdual
Handle latestdepends on sub resolvers
Handle publishdelegates to ivy sub resolver if artifact to publish is of "ivy" type, to artifact sub resolver otherwise
This resolver delegates its job to one resolver for ivy files and another for artifacts.

Attributes

This resolver shares the common attributes of composite resolvers.
AttributeDescriptionRequired
allownomdtrue if the absence of module descriptor (usually an ivy file) is authorised for this resolver, false to refuse modules without module descriptor since 1.4 No, defaults to true

Child elements

ElementDescriptionCardinality
any resolvertwo resolvers, the first being the ivy resolver, the second the artifact resolver 2

sftp resolver

Tag sftp
Handle latest yes
Handle publish yes



This resolver can be used when your ivy repository is located on a server accessible via sftp. The secured nature of sftp and its wide spread implementation on most *nix servers makes this resolver a very good candidate in an enterprise environment. since 1.4

If your server supports ssh but not sftp, there is also an ssh resolver.

Note that sftp is also supported by vfs, so you can use a vfs resolver instead. The advantage of this resolver is that you have a better control over authentication, it can prompt for username/password credentials, or you can use private/public key authentication, which is not possible with the vfs resolver. When it prompts for username/password, it uses a Swing dialog, which is not possible in a headless environment. If you want to prompt for the credentials on the command line, use ant input task for example before calling ivy.

All necessary connection parameters can be set here via attributes.
However all attributes defined in the pattern url of the resolver will have higher priority and will overwrite the values given here. To specify connection parameters in the pattern, you have to specify a full url and not just a path as pattern.
e.g. pattern="/path/to/my/repos/[artifact].[ext]" will use all connection parameters from this class
e.g. pattern="sftp://myserver.com/path/to/my/repos/[artifact].[ext]" will use all parameters from the attributes with the exception of the host, which will be "myserver.com"
e.g. pattern="sftp://user:geheim@myserver.com:8022/path/to/my/repos/[artifact].[ext]" will use only the keyFile and keyFilePassword from the attributes (if needed). Rest will come from the url.

Note that the authentication features of this resolver are exactly the same as the ssh resolver. Choosing between the two is often a matter of server implementation. If your server supports sftp, usually it's preferrable.

Internally this resolver relies on jsch as ssh client, which is a popular java ssh client, used for example in eclipse.

Attributes

This resolver shares the common attributes of standard resolvers.

Attribute Description Required
user The username to provide as credential No, defaults to username given on the patterns, or prompt if none is set
userPassword The password to provide as credential No, defaults to password given on the patterns, or prompt if none is set
keyFile Path to the keyfile to use for authentication No, defaults to username/password authentication
keyFilePassword the password used to protect the key file No, will prompt for password if keyFile authentication is used and if it is password encrypted
host The host to connect to No, defaults to host given on the patterns, fail if none is set
port The port to connect to No, defaults to 22

Child elements

Element Description Cardinality
ivy defines a pattern for ivy files, using the pattern attribute 0..n
artifact defines a pattern for artifacts, using the pattern attribute 1..n

Example

<sftp user="myuser" host="myhost.com">
  <ivy pattern="/path/to/ivy/[module]/ivy.xml"/>
  <artifact pattern="/path/to/[organisation]/[module]/[artifact].[ext]"/>
</sftp>

Will connect to myhost.com using myuser and prompt for the password.


<sftp user="${myuser}" userPassword="${my.password}" host="myhost.com">
  <ivy pattern="path/to/ivy/[module]/ivy.xml"/>
  <artifact pattern="path/to/[organisation]/[module]/[artifact].[ext]"/>
</sftp>

Will connect to myhost.com using user and password provided with ivy variables.


<sftp>
  <ivy pattern="sftp://user:geheim@yourserver.com:8022/path/to/repos/[module]/[revision]/ivy.xml"/>
  <artifact pattern="sftp://user:secret@myserver.com:8022/path/to/my/repos/[artifact].[ext]"/>
</sftp>

Will connect to yourserver.com on port 8022 with user 'user' and password 'geheim' for authentication for ivy files, and to myserver.com on port 8022 using user 'user' and password 'secret' for the artifacts.


<sftp keyFile="path/to/key/file" keyFilePassword="${password}">
  <ivy pattern="sftp://user@yourserver.com:8022/path/to/repos/[module]/[revision]/ivy.xml"/>
  <artifact pattern="sftp://user@myserver.com:8022/path/to/my/repos/[artifact].[ext]"/>
</sftp>

Will connect to yourserver.com on port 8022 with user 'user' and use keyFile path/to/key/file for keyFile and the value of password variable for keyFilePassword authentication for ivy files, and to myserver.com on port 8022 using user 'user' with the same keyFile/keyFilePassword pair for the artifacts.

ssh resolver

Tag ssh
Handle latest yes
Handle publish yes



This resolver can be used when your ivy repository is located on a server accessible via ssh. The secured nature of ssh and its wide spread implementation on most *nix servers makes this resolver a very good candidate in an enterprise environment. since 1.4

If your server supports sftp, you can consider using the sftp resolver.

Internally this resolver shares most of its behaviour with the sftp resolver, so refer to its documentation for details.

Attributes

This resolver shares the common attributes of standard resolvers.

Attribute Description Required
user The username to provide as credential No, defaults to username given on the patterns, or prompt if none is set
userPassword The password to provide as credential No, defaults to password given on the patterns, or prompt if none is set
keyFile Path to the keyfile to use for authentication No, defaults to username/password authentication
keyFilePassword the password used to protect the key file No, will prompt for password if keyFile authentication is used and if it is password encrypted
host The host to connect to No, defaults to host given on the patterns, fail if none is set
port The port to connect to No, defaults to 22

Child elements

Element Description Cardinality
ivy defines a pattern for ivy files, using the pattern attribute 0..n
artifact defines a pattern for artifacts, using the pattern attribute 1..n

Example

<ssh user="myuser" host="myhost.com">
  <ivy pattern="/path/to/ivy/[module]/ivy.xml"/>
  <artifact pattern="/path/to/[organisation]/[module]/[artifact].[ext]"/>
</ssh>

Will connect to myhost.com using myuser and prompt for the password.


<ssh keyFile="path/to/key/file" keyFilePassword="${password}">
  <ivy pattern="ssh://user:geheim@yourserver.com:8022/path/to/repos/[module]/[revision]/ivy.xml"/>
  <artifact pattern="ssh://user:geheim@myserver.com:8022/path/to/my/repos/[artifact].[ext]"/>
</ssh>

Will connect to yourserver.com on port 8022 with user geheim and use keyFile path/to/key/file for keyFile and the value of password variable for keyFilePassword authentication for ivy files, and to myserver.com on port 8022 using user geheim with the same keyFile/keyFilePassword pair for the artifacts.

vfs

Tag vfs
Handle latest depend on vfs capacity, usually yes
Handle publish depend on vfs capacity, usually yes



This resolver is certainly the most capable, since it relies on Apache commons VFS, which gives an uniform access to a good number of file systems, including ftp, webdav, zip, ... since 1.4

Note: commons vfs has not released a stable version yet, hence Ivy relies on a nightly build. Stability should thus be considered carefully before using this resolver in a production environment

Attributes

This resolver shares the common attributes of standard resolvers.

Child elements

Element Description Cardinality
ivy defines a pattern for ivy files, using the pattern attribute 0..n
artifact defines a pattern for artifacts, using the pattern attribute 1..n

Example

<vfs name="vfs-resolver">
  <ivy pattern="sftp://username:password@host/[organisation]/[module]/[revision]/ivy.xml" />
  <artifact pattern="sftp://username:password@host/[organisation]/[module]/[revision]/[artifact].[ext]" />
</vfs>

Access ivy and artifacts files using sftp.

conflict-managers

Tag: conflict-managers

Defines a list of conflicts managers usable in ivy. Each conflict manager is identified by its name, given as an attribute.
The child tag used for the conflict manager must be equal to a name of a conflict manager type (either built-in
or added with the typedef tag).

Here is a list of predefined conflicts managers (which do not require anything in the configuration file):

  • all
  • this conflicts manager resolve conflicts by selecting all revisions. Also called NoConflictManager, it does evict any module.

  • latest-time
  • this conflict manager selects only the 'latest' revision, latest being defined as the latest in time. Note that latest in time is costly to compute, so prefer latest-revision if you can.

  • latest-revision
  • this conflict manager selects only the 'latest' revision, latest being defined by a string comparison of revisions.

  • strict
  • this conflict manager throws an exception (i.e. causes a build failure) whenever a conflict is found.

The two "latest" conflict managers also take into account the force attribute of the dependencies.
Indeed direct dependencies can declare a force attribute (see dependency), which indicates the the revision given in the direct dependency should be prefered over indirect dependencies.

Here is a list of conflict manager types available, which can be used to define your own custom conflict managers:

  • latest-cm
  • The latest conflict manager uses a latest strategy to select the latest revision among several ones. Both latest-time and latest-revision conflict managers are based on this conflict manager type. It takes 'latest' as attribute to define which latest strategy should be used. Example:
    <latest-cm name="mylatest-conflict-manager" latest="my-latest-strategy"/>

  • regexp-cm
  • This conflict manager is based on a regular expression and throw an exception (i.e. causes a build failure) when a conflict is found with versions with different matching group. For instance if a conflict is found between 1.2.x and 1.3.y it will throw an exception if the regular exception is (.*)\.\d, because the matching group will match different string (1.2 and 1.3). 1.2.1 and 1.2.2 won't throw an exception with the same regular expression. The regular expression is set using the 'regexp' attribute. A 'ignoreNonMatching' attribute can also be set to simply warrn when a version is found which does not match the regular expression, instead of throwing an exception.

Child elements

Element Description Cardinality
any conflict manager adds a conflict manager to the list of available conflict managers 0..n

modules

Tag: modules

Defines per module or module set settings.

The rules are given by defining a module set, using pattern for module organisation and name, and giving some settings for the set, like the name of the corresponding resolver to use.

If no rule match a given module, the default setting will be used.

Even if not required, because the use of a default big resolver (chain, for instance) able to resolve all dependencies can answer all the needs, the configuration of smaller resolvers used for different cases can improve performances a lot. For instance, if you have a local repository for your modules and a distant repository for third party libraries, it is a good idea to have two separate resolvers, and configure ivy to use one for all your modules and another for the rest (the default one).

Child elements

Element Description Cardinality
module defines a module set rule 1..n

module

Tag: module

Define a module set rule. The tag defines a module set, by giving an expression and the matcher to use for organisation and name (for instance, you can use * to specify all).

It also gives the specific setting to use for this module set.

For each module set, you can configure:

Attributes

Attribute Description Required
organisation the name of the organisation to which apply the resolver. May be a regexp. Yes
name the name of the module to which apply the resolver. May be a regexp. Yes
matcher the matcher to use to match the modules to which the resolver should be applied since 1.3 No, defaults to exactOrRegexp in pre 1.3 ivy files, and exact in 1.3 and superior
resolver the name of the resolver to apply. The resolver must have been defined in the resolvers section of the configuration file. No
conflict-manager the name of the conflict manager to apply. since 1.4 No
branch the default branch to apply. since 1.4 No

Examples

<modules>
  <module organisation="jayasoft" name="*" resolver="myprojectsresolver"/>
</modules>

Uses myprojectresolver for all modules from jayasoft.


<modules>
  <module organisation="apache" name="commons-*" matcher="glob" resolver="myapachecommonsresolver"/>
</modules>

Uses myapachecommonsresolver for all modules beginning by commons- from apache.


<modules>
  <module organisation="apache" name="commons-[a-z]+" matcher="regexp" resolver="myapachecommonsresolver"/>
</modules>

Uses myapachecommonsresolver for all modules from apache beginning by commons- followed by any number of alphabetic lowercase characters.


<modules>
  <module organisation="jayasoft" name="ivy*" matcher="glob" conflict-manager="latest-time"/>
</modules>

Uses latest-time conflict manager for all modules from jayasoft which name begins with ivy.


<modules>
  <module organisation="jayasoft" name="ivy*" matcher="glob" branch="fix-103"/>
</modules>

Uses 'fix-103' as default branch for all modules from jayasoft which name begins with ivy.

outputters

Tag: outputters

Defines a list of report outputters usable in ivy.

A report outputter is used at the end of the resolve process to generate a report of how the resolve has been performed.

Two report outputters are registered by default:

  • a log report outputter (LogReportOutputter)
  • which produces the output on the console at the end of the resolve, which looks like this:

            ---------------------------------------------------------------------
            |                  |            modules            ||  artifacts  |
            |      conf      | number| search|dwnlded|evicted|| number|dwnlded|
            ---------------------------------------------------------------------
            |      default    |  1  |  1  |  0  |  0  ||  1  |  1  |
            ---------------------------------------------------------------------
  • an xml report outputter (XmlReportOutputter)
  • which produces an xml report in the cache, which is mandatory for correct Ivy behaviour, since it's that report which is used when you do a post resolve step in a separate buid from the resolve itself. It's also this xml report which is processed to generate all the different reports available in the report task.

The child tag used for the parser must be equal to a name of a report outputter type (added with the typedef tag).

To see how to define your own report outputter see Extending Ivy documentation

Child elements

Element Description Cardinality
any report outputter adds a report outputter to the list of available ones 0..n

statuses

Tag: statuses

Defines the list of available statuses. since 1.4

By default, ivy has 3 statuses: release, milestone and integration. By adding a statuses section to your ivyconf file, you define the statuses you want to use. Note that in this case if you still want to have ivy default statuses you will have to declare them.

The integration property on each status is only used for recursive delivery, an integration dependency being delivered if the caller is not in integration state itself.

The default status is the one used when none is defined in a module descriptor. If not specified, it defaults to the last defined status.

The statuses order is important, the first is considered the more mature, the last the less mature. This is used to know if a status is compatible with a latest. version matcher.

Attributes

Attribute Description Required
default the name of the status to use when none is declared in an ivy file No, defaults to the last status declared

Child elements

Element Description Cardinality
status defines a new status 0..n

Examples

<statuses default="bronze">
  <status name="gold" integration="false"/>
  <status name="silver" integration="false"/>
  <status name="bronze" integration="true"/>
</statuses>

Defines 3 statuses, gold, silver and bronze. The default status used when none is declared in an ivy file will be bronze.
It is also considered as an integration status, and thus doesn't trigger any recrusive delivery.

status

Tag: status

Define one available module status.

See statuses page for details about how statuses are defined.

Attributes

Attribute Description Required
name name of status defined Yes
integration true if this is an integration status, false otherwise No, defaults to false

triggers

Tag: triggers
since 1.4

Defines a list of triggers to activate on some Ivy events.

A trigger is an action which is performed whenever a particular event occurs.
Ivy supports two type of triggers out of the box: ant-call and ant-build. The first calls a target in the same build as the original one whenever a particular event occurs, the second call an ant build which may be in another ant build script.

If you want to use a different trigger, you can implement your own.

The event available in Ivy are the following ones:

Name Attributes Description
pre-resolve
  • organisation
  • the organisation of the module for which the dependencies will be resolved

  • module
  • the name of the module for which the dependencies will be resolved

  • revision
  • the revision of the module for which the dependencies will be resolved

  • conf
  • comma separated list of configurations which will be resolved

Fired before a module dependencies will be resolved
pre-resolve-dependency
  • organisation
  • the organisation of the dependency resolved

  • module
  • the name of the dependency resolved

  • revision
  • the revision asked for the dependency

  • resolver
  • the name of the resolver used to resolve the dependency

Fired before each dependency is resolved in a single resolve call
post-resolve-dependency
  • organisation
  • the organisation of the dependency resolved

  • module
  • the name of the dependency resolved

  • revision
  • the revision of the dependency resolved, or the revision asked if the resolution was not successful

  • resolved
  • true if the resolution was successful, false otherwise

  • resolver
  • the name of the resolver used to resolve the dependency

Fired after each dependency resolved in a single resolve call
post-resolve
  • organisation
  • the organisation of the module for which the dependencies have been resolved

  • module
  • the name of the module for which the dependencies have been resolved

  • revision
  • the revision of the module for which the dependencies have been resolved

  • conf
  • comma separated list of configurations resolved

Fired after a module dependencies has been resolved
pre-download-artifact
  • organisation
  • the organisation of the artifact which is about to be downloaded

  • module
  • the name of the module of the artifact which is about to be downloaded

  • revision
  • the revision of the the artifact which is about to be downloaded

  • artifact
  • the name of the the artifact which is about to be downloaded

  • type
  • the type of the the artifact which is about to be downloaded

  • ext
  • the extension of the the artifact which is about to be downloaded

  • resolver
  • the name of the resolver used to download the artifact

  • origin
  • the origin location from which it will be downloaded

  • local
  • true if it's a local artifact, false otherwise

Fired before an artifact is downloaded from a repository to the cache
post-download-artifact
  • organisation
  • the organisation of the artifact which was just downloaded

  • module
  • the name of the module of the artifact which was just downloaded

  • revision
  • the revision of the the artifact which was just downloaded

  • artifact
  • the name of the the artifact which was just downloaded

  • type
  • the type of the the artifact which was just downloaded

  • ext
  • the extension of the the artifact which was just downloaded

  • resolver
  • the name of the resolver used to download the artifact

  • origin
  • the origin location from which it was downloaded

  • local
  • true if it's a local artifact, false otherwise

  • size
  • the size in bytes of the downloaded artifact

  • file
  • the file to which it has been downloaded

Fired after an artifact has been downloaded from a repository to the cache

The child tag used for the dependency resolver must be equal to a name of a trigger type (either built-in or added with the typedef tag).

Child elements

Element Description Cardinality
any trigger adds a trigger to the list of registered triggers 1..n

Built-in Triggers

Ivy comes with two built-in triggers:

Name Description
ant-build Triggers an ant build.
ant-call Calls a target in the current ant build.

Common attributes

All triggers share some common attributes detailed here.

Among these attributes, you will find how to select when the trigger should be performed. You have to provide an event name, which is simple, but you can also use a filter expression. The syntax for this expression is very simple and limited:
you can use the = operator to compare an attribute (left operande) with a value (right operande).
you can use AND OR NOT as boolean operators
you cannot use parenthesis to change the precedence

Attribute Description Required
name the name of the trigger for identification purpose only Yes
event the name of the event on which the trigger should be performed Yes
filter a filter expression used to restrict when the trigger should be performed No, defaults to no filter

Examples

<triggers>
    <ant-build antfile="${ivy.conf.dir}/[module]/build.xml" target="publish"
          event="pre-resolve-dependency" filter="revision=latest.integration"/>
</triggers>

Triggers an ant build of the ant file ${ivy.conf.dir}/[module]/build.xml (where [module] is replaced by the name of the dependency resolved) with the target "publish", just before resolving a dependency with a latest.integration revision.


<triggers>
    <ant-call target="unzip" prefix="dep"
          event="post-download-artifact" filter="type=zip AND status=successful"/>
</triggers>

Triggers an ant call of the target unzip just after downloading a zip artifact, prefixing all parameters to the target with 'dep'.
Here is how the target can look like:

<target name="unzip">
    <echo>
        unzipping artifact:
        organisation=${dep.organisation}
        module=${dep.module}
        revision=${dep.revision}
        artifact=${dep.artifact}
        type=${dep.type}
        ext=${dep.ext}
        origin=${dep.origin}
        local=${dep.local}
        size=${dep.size}
        file=${dep.file}
    </echo>
    <mkdir dir="${basedir}/out"/>
    <unzip src="${dep.file}" dest="${basedir}/out"/>
</target>

version-matchers

Tag: version-matchers

Defines a list of version matchers. since 1.4

The child tag used for the version matcher must be equal to a name of a report outputter type (added with the typedef tag).

A version matcher is used to evaluate if a a dependency version contraint matches a dependency version.

See dependency doc for details about built-in version matchers.

Child elements

Element Description Cardinality
any version matcher adds a version matcher to the list of available ones 0..n