Reputation: 159
In ivyconf.xml, I have pattern='${ivy.settings.dir}/../../lib/Google Guava/[artifact].[ext]' />
. As you can see, I have wrote Google Guava
in the pattern. However, I have more than one jar file stored in another folder in same level of Google Guava
folder.
I have tried **
in place of Google Guava
, but I think it is not supported in ivyconf.xml. What should I wrote instead of Google Guava
so that it searches all folders to resolve dependencies?
ivyconf.xml
<resolvers>
<filesystem name="local">
<artifact
pattern='${ivy.settings.dir}/../../lib/Google Guava/[artifact].[ext]' />
</filesystem>
</resolvers>
<modules>
<module organisation='FS' resolver='local' />
</modules>
project structure
project
| - - - src
...
| - - - lib
| - - Google Guava
| - - guava.jar
| - - Folee
| - - folee-1.4.0.jar
Upvotes: 0
Views: 221
Reputation: 159
I have found how to solve it.
Firstly, I have changed the ivy.xml like;
<dependencies>
<dependency org="Google Guava" name="guava" rev="17.0"
conf="compile->default"/>
<dependency org="Folee" name="folee-1.4.0" rev="1.4.0"
conf="compile->default"/>
</dependencies>
Then, I have changed the ivyconf.xml like;
<conf defaultresolver="local"/>
<resolvers>
<filesystem name="local">
<artifact
pattern="${ivy.settings.dir}/../../lib/[organisation]/[artifact].[ext]" />
</filesystem>
</resolvers>
<modules>
<module resolver="local" />
</modules>
As you see, I havenot use organisation="FS"
to resolve them in own filesystem. Then, I used organisation
variable as container for storing folder name.
At last, what I got is the clean project hierarchy.
Upvotes: 1