Java Mailing List Archive

http://www.ant-tasks.com/

Home » Ant Users List »

RE: Retrieving key value pairs from URL and setting as system property

Burgess, Benjamin

2008-03-19

Replies:
You could do it as separate steps:

<get src="http://.../viewproperties" dest="downloaded.properties"
usetimestamp="true" />
<loadproperties srcFile="downloaded.properties"/>

You may also have to set <setproxy proxyhost="" />

Ben

-----Original Message-----
From: raju [mailto:raju_ak@(protected)]
Sent: Wednesday, March 19, 2008 7:23 AM
To: user@(protected)
Subject: Retrieving key value pairs from URL and setting as system
property


Hi,

I need to access a web URL say http://.../viewproperties which throws
plain
html with key value pairs as response.

Now as part of the main build i need to acces the above mentioned URL
and
set each of the key value pairs as system environment variables so that
they
are available other programs.

1)Is it possible to read url and access properties directly without
writing
to a properties file?

If we have to write to properties file to read it say like
<property url="http://www.mysite.com/bla/props/foo.properties"/>
Then how can we read a plain html and write its key-value pair to
propreties file?

2)How can we set the key values read as system environment variables
using
ANT?

Thanks and regards
Raj
--
http://www.nabble.com/Retrieving-key-value-pairs-from-URL-and-setting-as
-system-property-tp16142998p16142998.html
Sent from the Ant - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@(protected)
For additional commands, e-mail: user-help@(protected)

********************************************************************************************
This message, including any attachments, contains confidential information intended
for a specific individual and purpose, and is protected by law. If you are not the intended
recipient, please contact the sender immediately by reply e-mail and destroy all copies.
You are hereby notified that any disclosure, copying, or distribution of this message, or
the taking of any action based on it, is strictly prohibited.

TIAA-CREF
********************************************************************************************

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@(protected)
For additional commands, e-mail: user-help@(protected)

©2008 ant-tasks.com - Jax Systems, LLC, U.S.A.