You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Barry Pape <bp...@netspend.com> on 2010/04/15 00:08:20 UTC
Property File load issue
Hello All,
I have a user experiencing a frustrating issue with our ant + ivy
integration. The issue really has nothing to do with ivy except the
properties it needs are not loaded by ant. For some reason, on a single
desktop (that I know of) ant is not loading
${user.home}/build.properties. This setup works fine from various other
desktops and servers. From our build.xml, the property load task is:
<property file="${user.home}/build.properties"/>
Which is the second property definition in the build.xml, the first
being:
<property environment="env" />
I have verified that the file exists in C:\Documents and
Settings\<username> and that ${user.home} resolves correctly to
C:\Documents and Settings\<username>. I added echoes for the properties
that are set in ${user.home}/build.properties and none of them get set.
We tried hard coding the path, going up one level (C:\Documents and
Settings) with the path hard coded, and recreating the build.properties
file in ${user.home}, but none of these worked. Running using verbose,
ant indicates that C:\Documents and Settings\<username>\build.properties
does not exist (which it does). I don't see anything out of the
ordinary as far as extra spaces in the path or a carriage return that
would affect locating the file.
We are using ant 1.7, jdk 1.6.0_16, and Windows XP.
So far, I have not found a solution via google L
Any ideas?
Thanks,
Barry
Confidentiality Notice! This electronic transmission and any attached documents or other writings are confidential and are for the sole use of the intended recipient(s) identified above. This message may contain information that is privileged, confidential or otherwise protected from disclosure under applicable law. If the receiver of this information is not the intended recipient, or the employee, or agent responsible for delivering the information to the intended recipient, you are hereby notified that any use, reading, dissemination, distribution, copying or storage of this information is strictly prohibited. If you have received this information in error, please notify the sender by return email and delete the electronic transmission, including all attachments from your system.
Re: Property File load issue
Posted by Antoine Levy Lambert <an...@gmx.de>.
Hello Barry,
did you make sure that ${user.home} resolves on the problematic desktop
as "C:\Documents and Settings\[username]".
I have had frustrating cases when running CruiseControl as a service on
a Win32 box that ${user.home} was resolving to something unexpected.
I think Java looks up one's desktop directory from the registry, and
assumes that the home directory is the parent directory of the desktop
directory.
If everything else fails, try to start ant with a
-Duser.home="C:\Documents and Settings\JohnDoe"
Regards,
Antoine
Barry Pape wrote:
> Hello All,
>
>
>
> I have a user experiencing a frustrating issue with our ant + ivy
> integration. The issue really has nothing to do with ivy except the
> properties it needs are not loaded by ant. For some reason, on a single
> desktop (that I know of) ant is not loading
> ${user.home}/build.properties. This setup works fine from various other
> desktops and servers. From our build.xml, the property load task is:
>
> <property file="${user.home}/build.properties"/>
>
>
>
> Which is the second property definition in the build.xml, the first
> being:
>
> <property environment="env" />
>
>
>
> I have verified that the file exists in C:\Documents and
> Settings\<username> and that ${user.home} resolves correctly to
> C:\Documents and Settings\<username>. I added echoes for the properties
> that are set in ${user.home}/build.properties and none of them get set.
> We tried hard coding the path, going up one level (C:\Documents and
> Settings) with the path hard coded, and recreating the build.properties
> file in ${user.home}, but none of these worked. Running using verbose,
> ant indicates that C:\Documents and Settings\<username>\build.properties
> does not exist (which it does). I don't see anything out of the
> ordinary as far as extra spaces in the path or a carriage return that
> would affect locating the file.
>
>
>
> We are using ant 1.7, jdk 1.6.0_16, and Windows XP.
>
>
>
> So far, I have not found a solution via google L
>
>
>
> Any ideas?
>
>
>
> Thanks,
>
> Barry
>
> Confidentiality Notice! This electronic transmission and any attached documents or other writings are confidential and are for the sole use of the intended recipient(s) identified above. This message may contain information that is privileged, confidential or otherwise protected from disclosure under applicable law. If the receiver of this information is not the intended recipient, or the employee, or agent responsible for delivering the information to the intended recipient, you are hereby notified that any use, reading, dissemination, distribution, copying or storage of this information is strictly prohibited. If you have received this information in error, please notify the sender by return email and delete the electronic transmission, including all attachments from your system.
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org