Return-Path: Mailing-List: contact user-help@ant.apache.org; run by ezmlm Delivered-To: mailing list user@ant.apache.org Received: (qmail 27033 invoked from network); 28 May 2003 13:58:11 -0000 Received: from ext-nj2gw-2.online-age.net (216.35.73.164) by daedalus.apache.org with SMTP; 28 May 2003 13:58:11 -0000 Received: from int-nj2gw-2.online-age.net (int-nj2gw-2 [3.159.236.66]) by ext-nj2gw-2.online-age.net (8.12.9/8.12.8/990426-RLH) with ESMTP id h4SDwAFt010196 for ; Wed, 28 May 2003 09:58:10 -0400 (EDT) Received: from AP3EXVW01APPLGE.appl.ge.com (localhost [127.0.0.1]) by int-nj2gw-2.online-age.net (8.12.9/8.12.8/990426-RLH) with SMTP id h4SDw2OZ003153 for ; Wed, 28 May 2003 09:58:04 -0400 (EDT) Received: from 3.130.163.181 by AP3EXVW01APPLGE.appl.ge.com (InterScan E-Mail VirusWall NT); Wed, 28 May 2003 10:00:15 -0400 Received: by exchange.appl.ge.com with Internet Mail Service (5.5.2653.19) id ; Wed, 28 May 2003 10:00:15 -0400 Message-ID: <62E407E3139D564FBFD7273C369F323101DBBB5D@banexpr01applge.appl.ge.com> From: "Verma, Nitin (GECP, OTHER, 529706)" To: Ant Users List Subject: RE: How to use properties iteration? Date: Wed, 28 May 2003 10:00:05 -0400 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: multipart/mixed; boundary="----=_NextPartTM-000-0700ba23-bd14-4917-a51d-e2d64f7549c4" X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N ------=_NextPartTM-000-0700ba23-bd14-4917-a51d-e2d64f7549c4 Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01C32521.711CFEE0" ------_=_NextPart_001_01C32521.711CFEE0 Content-Type: text/plain; charset="iso-8859-1" ftp://www-126.ibm.com/ is down ... I think So I get a jar from http://xml.apache.org/dist/soap/version-2.2/ ! Now I get "file:E:/projects/ts/serverconfig/serverconfig-appinstance/classpath.xml:13: com.ibm.bsf.BSFException: unsupported language: jython" Can you please mail me the write version please! -----Original Message----- From: peter reilly [mailto:peter.reilly@corvil.com] Sent: Wednesday, May 28, 2003 6:57 PM To: Ant Users List Subject: Re: How to use properties iteration? On Wednesday 28 May 2003 14:16, Verma, Nitin (GECP, OTHER, 529706) wrote: > Thanx so much ... but I get "Could not create task or type of type: > script." > > Do I need some *.jar files for jpython? You need bsf.jar from ibm and jython.jar from jython.org - check the ant manual. - For ant 1.6 and above, bsf.jar comes from apache. (I am using ant 1.6 alpha with bsf.jar) Peter > > -----Original Message----- > From: peter reilly [mailto:peter.reilly@corvil.com] > Sent: Wednesday, May 28, 2003 6:43 PM > To: Ant Users List > Subject: Re: How to use properties iteration? > > > You need to use > > > > > > Peter > > On Wednesday 28 May 2003 13:36, Verma, Nitin (GECP, OTHER, 529706) wrote: > > I can have n number of jars, so:- > > > > I need to have something like this: > > > > > > > > > > > > > > > > > > > > > > > > > value="${jar.location}/${jar.name}-${jar.version}.jar"/> > > > > > > > > > > > > Help please! > > > > Regards, > > > > Nitin Verma > > > > -----Original Message----- > > From: Manoj Sadangi [mailto:msadangi@manh.com] > > Sent: Wednesday, May 28, 2003 5:46 PM > > To: 'Ant Users List' > > Subject: RE: How to use properties iteration? > > > > > > > > load the properties file > > and you can access the properties and construct the path like > > ${jar.telnet.location}/${jar.1.name }/...... > > > > > > > > thanks, > > manoj > > > > > > -----Original Message----- > > From: Verma, Nitin (GECP, OTHER, 529706) [mailto:NITIN.VERMA@APPL.GE.COM] > > Sent: Wednesday, May 28, 2003 7:57 AM > > To: Ant Users List > > Subject: How to use properties iteration? > > > > > > > > Hi All, > > > > I have properties like: > > jar.1.name = telnet > > jar.telnet.location=/home/my > > jar.telnet.version = 1.0 > > jar.1.name = ssh > > jar.ssh.location=/home/his > > jar.ssh.version = 1.2 > > > > Now I need to make a path like:- > > > > /home/my/telnet-1.0.jar:/home/his/ssh-1.2.jar > > > > Can someone help me on this? > > > > Regards, > > > > Nitin Verma > > --------------------------------------------------------------------- > To unsubscribe, e-mail: user-unsubscribe@ant.apache.org > For additional commands, e-mail: user-help@ant.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org ------_=_NextPart_001_01C32521.711CFEE0 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable RE: How to use properties iteration?

ftp://www-126.ibm.com/ is down ... I think
So I get a jar from http://xml.apache.org/dist/soap/version-2.2/ = !



Now I get = "file:E:/projects/ts/serverconfig/serverconfig-appinstance/classpat= h.xml:13: com.ibm.bsf.BSFException: unsupported language: = jython"

Can you please mail me the write version = please!

-----Original Message-----
From: peter reilly [mailto:peter.reilly@corvil.com]
Sent: Wednesday, May 28, 2003 6:57 PM
To: Ant Users List
Subject: Re: How to use properties iteration?


On Wednesday 28 May 2003 14:16, Verma, Nitin (GECP, = OTHER, 529706) wrote:
> Thanx so much ... but I get "Could not = create task or type of type:
> script."
>
> Do I need some *.jar files for jpython?

You need bsf.jar from ibm and jython.jar from = jython.org -
check the ant manual. -

For ant 1.6 and above, bsf.jar comes from = apache.

(I am using ant 1.6 alpha with bsf.jar)

Peter
>
> -----Original Message-----
> From: peter reilly [
mailto:peter.reilly@corvil.com]
> Sent: Wednesday, May 28, 2003 6:43 PM
> To: Ant Users List
> Subject: Re: How to use properties = iteration?
>
>
> You need to use <script/>
>
> Here is an example with jython:
>
> <project name=3D"t" = default=3D"t">
>   <target = name=3D"t">
>     <concat = destfile=3D"x.properties">
> jar.1.name =3D telnet
> jar.telnet.location=3D/home/my
> jar.telnet.version =3D 1.0
> jar.2.name =3D ssh
> jar.ssh.location=3D/home/his
> jar.ssh.version =3D 1.2
>     </concat>
>     <property = file=3D"x.properties"/>
>     <script = language=3D"jython">
> import java.util.TreeMap as TreeMap
> import java.lang.Integer as Integer
> sorted =3D TreeMap()
> props  =3D project.getProperties()
> for x in props.keys():
>     if = x.find("jar") =3D=3D 0 and x.find("name") !=3D = -1:
>         = num =3D x[4:x.find("name")-1]
>         = sorted.put(Integer.decode(num), props.get(x))
>         = print x
>         = print num
> result =3D ""
> for x in sorted.keySet():
>     name =3D = sorted.get(x)
>     = location=3Dprops.get("jar." + name + = ".location")
>     = version=3Dprops.get("jar." + name + = ".version")
>     if result !=3D = "":
>         = result =3D result + ":"
>     result =3D result + = location + "/" + name + "-" + version + = ".jar"
> = project.setUserProperty("my.classpath", result)
>     </script>
>
>     <echo = message=3D"CP is ${my.classpath}"/>
>   </target>
> </project>
>
> Peter
>
> On Wednesday 28 May 2003 13:36, Verma, Nitin = (GECP, OTHER, 529706) wrote:
> > I can have n number of jars, so:-
> >
> > I need to have something like this:
> >
> > <!--I don't know how to make while loop = using ant -->
> > <while = condition=3D"true">
> >     <property = name=3D"jar.name" = value=3D"java.${i}.name"/>
> > <!--I don't know how to do this using = ant -->
> >     <if = condition=3D"${jar.name} =3D=3D null">
> = >         = <break/>
> >     </if>
> > <!-- = ----------------------------------------------------- -->
> >     <property = name=3D"jar.version" = value=3D"jar.${jar.name}.version"/>
> >     <property = name=3D"jar.location" = value=3D"jar.${jar.name}.location"/>
> >     <property = name=3D"jar.path"
> > = value=3D"${jar.location}/${jar.name}-${jar.version}.jar"/><= /FONT>
> >     <property = name=3D"classpath" append=3D"jar.path"/> <!-- = I need to append
>
> to
>
> > a property, I don't know how to do = this?-->
> > <!-- who to do "i++"? = -->
> > </while>
> > <!-- = ----------------------------------------------------- -->
> >
> > Help please!
> >
> > Regards,
> >
> > Nitin Verma
> >
> >  -----Original Message-----
> > From: Manoj Sadangi [
mailto:msadangi@manh.com]
> > Sent: Wednesday, May 28, 2003 5:46 = PM
> > To: 'Ant Users List'
> > Subject: RE: How to use properties = iteration?
> >
> >
> >
> > load the properties file
> > and you can access the properties and = construct the path like
> > ${jar.telnet.location}/${jar.1.name = }/......
> >
> >
> >
> > thanks,
> > manoj
> >
> >
> >  -----Original Message-----
> > From: Verma, Nitin (GECP, OTHER, 529706) = [mailto:NITIN.VERMA@APPL.GE.COM]
> > Sent: Wednesday, May 28, 2003 7:57 = AM
> > To: Ant Users List
> > Subject: How to use properties = iteration?
> >
> >
> >
> > Hi All,
> >
> = >         I have properties = like:
> = >           &n= bsp;     jar.1.name =3D telnet
> = >           &n= bsp;     jar.telnet.location=3D/home/my
> = >           &n= bsp;     jar.telnet.version =3D 1.0
> = >           &n= bsp;     jar.1.name =3D ssh
> = >           &n= bsp;     jar.ssh.location=3D/home/his
> = >           &n= bsp;     jar.ssh.version =3D 1.2
> >
> = >         Now I need to make = a path like:-
> >
> = >           &n= bsp;     = /home/my/telnet-1.0.jar:/home/his/ssh-1.2.jar
> >
> > Can someone help me on this?
> >
> > Regards,
> >
> > Nitin Verma
>
> = ---------------------------------------------------------------------
> To unsubscribe, e-mail: = user-unsubscribe@ant.apache.org
> For additional commands, e-mail: = user-help@ant.apache.org


---------------------------------------------------------------= ------
To unsubscribe, e-mail: = user-unsubscribe@ant.apache.org
For additional commands, e-mail: = user-help@ant.apache.org

------_=_NextPart_001_01C32521.711CFEE0-- ------=_NextPartTM-000-0700ba23-bd14-4917-a51d-e2d64f7549c4--