Hi, I am having some troubles getting the source publication to work.
The ivy.xml
<?xml version="1.0" encoding="UTF-8"?>
<ivy-module version="2.0">
<info module="${ant.project.name}" organisation="com.company"
revision="${version}"/>
<configurations>
<conf name="compile" extends="runtime"/>
<conf name="runtime" transitive="false" />
</configurations>
<publications>
<artifact name="${ant.project.name}" type="jar" ext="jar"/>
<artifact name="${ant.project.name}-source" type="source" ext="jar"
/>
</publications>
<dependencies>
<dependency org="com.company" name="report-commons" rev="1.0"
conf="compile->default" />
<dependency org="com.company" name="commons-framework" rev="0.1"
conf="compile->default" />
</dependencies>
</ivy-module>
The relevant build.xml related to publish
<ivy:publish overwrite="true" resolver="local-ivy-cache">
<artifacts pattern="${dist.dir}/[module]-[revision].[ext]" />
<artifacts pattern="${dist.dir}/[module]-[revision]-source.[ext]" />
</ivy:publish>
The ant output
publish:
[jar] Building jar:
c:\alphaworks_company\report-web\report-provider\dist\report-provider-1.6-source.jar
[ivy:publish] :: loading settings :: file =
c:\alphaworks_company\report-web\ivysettings.xml
:: delivering :: com.company#report-provider;1.6 :: 1.6 :: integration ::
Wed Jan 27 20:21:02 BRST 2010
delivering ivy file to
c:\alphaworks_company\report-web\report-provider\dist\report-provider-1.6.xml
:: publishing :: com.company#report-provider
published report-provider to
c:/temp/ivy-cache/com.company/report-provider/jars/report-provider-1.6.jar
published report-provider-source to
c:/temp/ivy-cache/com.company/report-provider/sources/report-provider-source-1.6.jar
published ivy to
c:/temp/ivy-cache/com.company/report-provider/ivys/ivy-1.6.xml
The
c:/temp/ivy-cache/com.company/report-provider/sources/report-provider-source-1.6.jar
is the same file as
c:/temp/ivy-cache/com.company/report-provider/jars/report-provider-1.6.jar
The generated jar files at report-provider\dist are (they are correct)
report-provider-1.6-source.jar - size 6.003
report-provider-1.6.jar - size 9.152
So, how to publish the source jar file correctly ?
Thanks
Claudio
-----
Claudio Miranda
http://weblogs.java.net/blog/claudio
http://www.claudius.com.br/blog
--
View this message in context:
http://old.nabble.com/Publish-the-source-jar---the-jar-file-is-the-binary-tp27347927p27347927.html
Sent from the ivy-user mailing list archive at Nabble.com.