I'm using Ivy to map artifacts of a project repository into individual
subprojects. This usually works fine. But I'm currently facing the problem
that Ivy picks the wrong artifacts for the following cases:
<dependency org="org.apache" name="poi" rev="[3.0,)"
conf="bundle->default"/>
<dependency org="org.apache" name="poi-scratchpad" rev="[3.0,)"
conf="bundle->default"/>
In the repository:
org.apache/poi-3.2-FINAL-20081019.jar
org.apache/poi-scratchpad-3.2-FINAL-20081019.jar
and
<dependency org="org.apache" name="jackrabbit-spi" rev="[1.4,)"
conf="bundle->default"/>
<dependency org="org.apache" name="jackrabbit-spi-commons" rev="[1.4,)"
conf="bundle->default"/>
In the repository:
org.apache/jackrabbit-spi-1.4.jar
org.apache/jackrabbit-spi-commons-1.4.jar
For example, jackrabbit-spi-commons-1.4.jar is picked for "jackrabbit-spi",
so I end up with the same JAR under two names.
In the log:
[ivy:cachepath] found org.apache#jackrabbit-spi;commons-1.4 in libraries
[ivy:cachepath] [commons-1.4] org.apache#jackrabbit-spi;[1.4,)
[ivy:cachepath] found org.apache#jackrabbit-spi-commons;1.4 in libraries
[ivy:cachepath] [1.4] org.apache#jackrabbit-spi-commons;[1.4,)
My ivysettings.xml looks like this:
<ivysettings>
<property name="repository.dir"
value="${ivy.settings.dir}/../build-repository" override="false"/>
<settings defaultResolver="project"
defaultLatestStrategy="mylatest-time"/>
<latest-strategies>
<latest-time name="mylatest-time"/>
</latest-strategies>
<resolvers>
<chain name="project">
<filesystem name="libraries" changingPattern="^.+-dev.*"
latest="mylatest-time">
<artifact
pattern="${repository.dir}/[organisation]/[module]-[revision].[ext]" />
<artifact
pattern="${repository.dir}/[organisation]/[module]_[revision].[ext]" />
</filesystem>
</chain>
</resolvers>
</ivysettings>
How can I change the configuration so the right artifacts are picked? Can I
improve the pattern for the artifacts somehow? Or can I somehow force a
regexp expression for valid version names so I can avoid versions like
[commons-1.4]? Of course, I could resolve this by renaming the artifacts.
But that's really just a work-around I'd like to avoid.
Thanks for any help. I've been trying this for hours.
Jeremias Maerki
--
View this message in context:
http://www.nabble.com/resolve-picks-wrong-artifact-tp22792468p22792468.html
Sent from the ivy-user mailing list archive at Nabble.com.