Hi,
(in case of formatting problems, I've put a copy of this email here:
http://pastebin.com/m44b795a1)
I'm having a problem publishing my sources to a local repo. This is what I have:
ivysettings.xml
<ivysettings>
<settings defaultResolver="default" />
<resolvers m2compatible="true">
<chain name="default" returnFirst="true" checkmodified="true">
<ibiblio name="ibiblio" m2compatible="true" />
<ibiblio name="sourceforge-ehcache" m2compatible="true"
root="http://oss.sonatype.org/content/groups/sourceforge/" />
<filesystem name="local">
<ivy
pattern="${ivy.default.ivy.user.dir}/local/[organisation]/[module]/[revision]/[type]s/[artifact]-[revision].xml"
/>
<artifact
pattern="${ivy.default.ivy.user.dir}/local/[organisation]/[module]/[revision]/[type]s/[artifact]-[revision].[ext]"
/>
</filesystem>
</chain>
</resolvers>
<modules>
<module organisation="net.sf.ehcache" name=".*"
resolver="sourceforge-ehcache" />
</modules>
</ivysettings>
my ivy.xml
<publications>
<artifact name="myapp" type="jar" ext="jar" />
<artifact name="myapp-sources" type="source" ext="jar" />
</publications>
and in my build.xml, I have this:
<target name="publish-locally">
<ivy:publish resolver="local" organisation="fu.bar"
module="${ant.project.name}" revision="${dist.version}"
forcedeliver="true" overwrite="true">
<artifacts
pattern="${dist.tmp.dir}/[type]s/[artifact]-[revision].[ext]" />
</ivy:publish>
</target>
When I produce my jars I end up with this:
dist/jars/myapp-0.1.jar
dist/sources/myapp-sources-0.1.jar
Yet, when I publish, all I end up is with the myapp-0.1.jar
This is the debug output:
publish-locally:
[ivy:publish] :: Ivy 2.1.0 - 20090925235825 :: http://ant.apache.org/ivy/ ::
[ivy:publish] :: loading settings :: file =
/Users/fubar/Javastuff/eclipse/workspaces/main/myapp/ivysettings.xml
:: delivering :: fu.bar#myapp;0.1 :: 0.1 :: integration :: Wed Feb 10
22:20:44 CET 2010
delivering ivy file to
/Users/fubar/Javastuff/eclipse/workspaces/main/myapp/tmp/dist/ivys/ivy-0.1.xml
:: publishing :: fu.bar#myapp
published promoweb to
/Users/fubar/.ivy2/local/fu.bar/myapp/0.1/jars/myapp-0.1.jar
published ivy to
/Users/fubar/.ivy2/local/fu.bar/fu.bar/0.1/ivys/ivy-0.1.xml
Funnily enough, when I examine the ivy-0.1.xml, I only have this under
publications:
<publications>
<artifact name="myapp" type="jar" ext="jar" />
</publications>
I'm really at a loss to understand why this isn't working. I had a
look thru the mailing list, tried a few things
but still no joy :-(
Anyone spot any glaringly obvious error I'm doing?
-=david=-