You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ivy-user@ant.apache.org by Shawn Castrianni <Sh...@halliburton.com> on 2007/12/29 08:56:04 UTC

problems with subant and publish

It seems that my ivy build via subant does not work during for the publish target, but it does work if I run it normally outside of subant.  I echoed the properties for when it did work and when it didn't.  The only difference I could see was my user.dir and user.dir.ivy.instance was different.  When running with the master build which calls subant, the user.dir is the directory of the master build.  When running the specific build standalone (not using subant from master build), the user.dir is the directory of the specific build.  Does this mean the publish task is working off of user.dir when delivering the resolved ivy.xml file?  How can I fix this?

---
Shawn Castrianni

----------------------------------------------------------------------
This e-mail, including any attached files, may contain confidential and privileged information for the sole use of the intended recipient.  Any review, use, distribution, or disclosure by others is strictly prohibited.  If you are not the intended recipient (or authorized to receive information for the intended recipient), please contact the sender by reply e-mail and delete all copies of this message.

Re: problems with subant and publish

Posted by Xavier Hanin <xa...@gmail.com>.
On Dec 29, 2007 9:22 AM, Shawn Castrianni <Sh...@halliburton.com>
wrote:

> I was able to work around this problem by removing all relative paths from
> my build files by adding ${basedir} in front of everything.  I think the
> real key was adding ${basedir} in front of my publish artifacts pattern.  I
> still think this is a bug in ivy:publish task since these tasks should be
> relative against ${basedir} automatically, and not the working directory at
> the time ant was launched.  Correct?  Or am I understanding how Ant works
> incorrectly?

We currently have several relative paths issues in Ivy:
https://issues.apache.org/jira/browse/IVY-387

This should be fixed in Ivy 2 final, ATM the workaround is to use absolute
paths.

Xavier

>
>
> ---
> Shawn Castrianni
>
>
> From: Shawn Castrianni
> Sent: Saturday, December 29, 2007 1:56 AM
> To: 'ivy-user@incubator.apache.org'
> Subject: problems with subant and publish
>
> It seems that my ivy build via subant does not work during for the publish
> target, but it does work if I run it normally outside of subant.  I echoed
> the properties for when it did work and when it didn't.  The only difference
> I could see was my user.dir and user.dir.ivy.instance was different.  When
> running with the master build which calls subant, the user.dir is the
> directory of the master build.  When running the specific build standalone
> (not using subant from master build), the user.dir is the directory of the
> specific build.  Does this mean the publish task is working off of
> user.dir when delivering the resolved ivy.xml file?  How can I fix this?
>
> ---
> Shawn Castrianni
>
> ----------------------------------------------------------------------
> This e-mail, including any attached files, may contain confidential and
> privileged information for the sole use of the intended recipient.  Any
> review, use, distribution, or disclosure by others is strictly prohibited.
>  If you are not the intended recipient (or authorized to receive information
> for the intended recipient), please contact the sender by reply e-mail and
> delete all copies of this message.
>



-- 
Xavier Hanin - Independent Java Consultant
http://xhab.blogspot.com/
http://ant.apache.org/ivy/
http://www.xoocode.org/

RE: problems with subant and publish

Posted by Shawn Castrianni <Sh...@halliburton.com>.
I was able to work around this problem by removing all relative paths from my build files by adding ${basedir} in front of everything.  I think the real key was adding ${basedir} in front of my publish artifacts pattern.  I still think this is a bug in ivy:publish task since these tasks should be relative against ${basedir} automatically, and not the working directory at the time ant was launched.  Correct?  Or am I understanding how Ant works incorrectly?

---
Shawn Castrianni


From: Shawn Castrianni
Sent: Saturday, December 29, 2007 1:56 AM
To: 'ivy-user@incubator.apache.org'
Subject: problems with subant and publish

It seems that my ivy build via subant does not work during for the publish target, but it does work if I run it normally outside of subant.  I echoed the properties for when it did work and when it didn't.  The only difference I could see was my user.dir and user.dir.ivy.instance was different.  When running with the master build which calls subant, the user.dir is the directory of the master build.  When running the specific build standalone (not using subant from master build), the user.dir is the directory of the specific build.  Does this mean the publish task is working off of user.dir when delivering the resolved ivy.xml file?  How can I fix this?

---
Shawn Castrianni

----------------------------------------------------------------------
This e-mail, including any attached files, may contain confidential and privileged information for the sole use of the intended recipient.  Any review, use, distribution, or disclosure by others is strictly prohibited.  If you are not the intended recipient (or authorized to receive information for the intended recipient), please contact the sender by reply e-mail and delete all copies of this message.