Hello! My question is on stackoverflow site too (here<http://stackoverflow.com/questions/29805969/using-a-configuration-intersection-in-ivy>). I would be very thankful for your help.
We use ant\ivy to manage our dependencies. And we want to download a minimum quantity of modules: only those are needed for build. I try to use a configuration intersection, but I got a not expecting ivy behavior. https://ant.apache.org/ivy/history/latest-milestone/ivyfile/dependency.html Blockquote since 2.1 It is also possible to define dependencies on configurations intersection. A configuration intersection is defined using a '+' sign to separate the configuration (eg 'A+B' means the intersection of configuration 'A' and 'B'). In that case only artifacts and dependencies defined in both configurations in the dependency will be part of the master configuration defining the dependency on the configuration intersection. build.xml file: <project xmlns:ivy="antlib:org.apache.ivy.ant" xmlns:e="http://ant.apache.org/ivy/extra" name="test" default="get"> <target name="get" description="-->Downloads all artifacts and prepare it"> <ivy:resolve file="ivy.xml" conf="${conf}" /> </target> </project> ivy file: <?xml version="1.0" encoding="utf-8"?> <ivy-module version="2.0" xmlns:e="http://ant.apache.org/ivy/extra"> <info module="test" organisation="main" revision="1.0"/> <configurations> <conf name="release" e:axis="download_type" /> <conf name="dev" e:axis="download_type" /> <conf name="client" e:axis="product"/> <conf name="server" e:axis="product"/> </configurations> <dependencies> <dependency org="main" name="zlib" branch="trunk" rev="1.2.8.+" conf="dev->*;client->*"/> </dependencies> </ivy-module> case 1: ant -Dconf="dev+server" case 2: ant -Dconf="server+dev" I expect that the results are same in first and second case: zlib shouldn't be downloaded, because the intersection of "Dev" and "Server" confs is nothing. But I get: · in case 1: Zlib is not dowloaded · in case 2: Zlib is dowloaded Where is my misunderstanding? Thanks