You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Ravi Roy <ra...@gmail.com> on 2007/10/06 07:23:15 UTC
Showing current classpath Ant is using in Build executing state
Hi All,
In a scenario, where build is executing how I can see / log the current
classpath of this build, which Ant is relying to build the project ?
I think Ant -diagnositcs gives the interesting informarmation but not in the
build executing state and is static in nature.
Thanks in advance for thoughts!
Regards,
Ravi.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
AW: AW: Showing current classpath Ant is using in Build executing state
Posted by Knuplesch,
Jürgen <Ju...@icongmbh.de>.
Thank you! This is great, because I always was thinking of sth. Like that.
There are so many problems with the classpath...
--
Jürgen Knuplesch www.icongmbh.de
icon Systemhaus GmbH Tel. +49 711 806098-275
Sophienstraße 40
D-70178 Stuttgart Fax. +49 711 806098-299
Geschäftsführer: Uwe Seltmann
HRB Stuttgart 17655
USt-IdNr.: DE 811944121
-----Ursprüngliche Nachricht-----
Von: Steve Loughran [mailto:stevel@apache.org]
Gesendet: Montag, 8. Oktober 2007 12:42
An: Ant Users List
Betreff: Re: AW: Showing current classpath Ant is using in Build executing state
Knuplesch wrote:
> Hello,
>
> Depending on the task you use, you can define a lot of classpaths.
> I usually use the classpath or classpathref attribute to set the classpath e.g. for the javac task.
>
> The question is: For which task you need the classpath and how do you set the classpath??
>
> This is how i trace the classpath, if it is stored in a refid:
> <property name="ausgabejunit" refid="junit.classpath" />
> <echo>Klassenpfad in junit: classpath=${ausgabejunit}</echo>
>
Actually, you can skip the conversion by calling toString on the classpath (since ant1.6)
<echo>Klassenpfad in junit: classpath=${toString:junit.classpath}</echo>
We use <pathconvert> to split our classpath up with newlines before printing
<!-- to get the classpath in a printable form -->
<pathconvert pathsep="${line.separator}| |-- "
property="echo.compile.classpath"
refid="compile.classpath">
</pathconvert>
<echo message="
--------------------------------------------------------"/>
<echo message=" Project: ${ant.project.name}"/>
<echo message=" Ant file: ${ant.file}"/>
<echo message=" Compile Class Path= ${line.separator}|
|-- ${echo.compile.classpath}"/>
<echo message="
--------------------------------------------------------"/>
--
Steve Loughran http://www.1060.org/blogxter/publish/5
Author: Ant in Action http://antbook.org/
---------------------------------------------------------------------
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
Re: AW: Showing current classpath Ant is using in Build executing
state
Posted by Steve Loughran <st...@apache.org>.
Knuplesch wrote:
> Hello,
>
> Depending on the task you use, you can define a lot of classpaths.
> I usually use the classpath or classpathref attribute to set the classpath e.g. for the javac task.
>
> The question is: For which task you need the classpath and how do you set the classpath??
>
> This is how i trace the classpath, if it is stored in a refid:
> <property name="ausgabejunit" refid="junit.classpath" />
> <echo>Klassenpfad in junit: classpath=${ausgabejunit}</echo>
>
Actually, you can skip the conversion by calling toString on the
classpath (since ant1.6)
<echo>Klassenpfad in junit: classpath=${toString:junit.classpath}</echo>
We use <pathconvert> to split our classpath up with newlines before printing
<!-- to get the classpath in a printable form -->
<pathconvert pathsep="${line.separator}| |-- "
property="echo.compile.classpath"
refid="compile.classpath">
</pathconvert>
<echo message="
--------------------------------------------------------"/>
<echo message=" Project: ${ant.project.name}"/>
<echo message=" Ant file: ${ant.file}"/>
<echo message=" Compile Class Path= ${line.separator}|
|-- ${echo.compile.classpath}"/>
<echo message="
--------------------------------------------------------"/>
--
Steve Loughran http://www.1060.org/blogxter/publish/5
Author: Ant in Action http://antbook.org/
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
AW: Showing current classpath Ant is using in Build executing state
Posted by Knuplesch,
Jürgen <Ju...@icongmbh.de>.
Hello,
Depending on the task you use, you can define a lot of classpaths.
I usually use the classpath or classpathref attribute to set the classpath e.g. for the javac task.
The question is: For which task you need the classpath and how do you set the classpath??
This is how i trace the classpath, if it is stored in a refid:
<property name="ausgabejunit" refid="junit.classpath" />
<echo>Klassenpfad in junit: classpath=${ausgabejunit}</echo>
Greetings
--
Jürgen Knuplesch www.icongmbh.de
icon Systemhaus GmbH Tel. +49 711 806098-275
Sophienstraße 40
D-70178 Stuttgart Fax. +49 711 806098-299
Geschäftsführer: Uwe Seltmann
HRB Stuttgart 17655
USt-IdNr.: DE 811944121
-----Ursprüngliche Nachricht-----
Von: Ravi Roy [mailto:ravi.aroy@gmail.com]
Gesendet: Samstag, 6. Oktober 2007 07:23
An: user@ant.apache.org
Betreff: Showing current classpath Ant is using in Build executing state
Hi All,
In a scenario, where build is executing how I can see / log the current classpath of this build, which Ant is relying to build the project ?
I think Ant -diagnositcs gives the interesting informarmation but not in the build executing state and is static in nature.
Thanks in advance for thoughts!
Regards,
Ravi.
---------------------------------------------------------------------
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
RE : Showing current classpath Ant is using in Build executing state
Posted by Bourzeix,
Hervé <He...@Genesys.com>.
try -verbose in your ant argument line , otherwise do a pathconvert / echo inside the build
regards,
-------- Message d'origine--------
De: Ravi Roy [mailto:ravi.aroy@gmail.com]
Date: sam. 06/10/2007 07:23
À: user@ant.apache.org
Objet : Showing current classpath Ant is using in Build executing state
Hi All,
In a scenario, where build is executing how I can see / log the current
classpath of this build, which Ant is relying to build the project ?
I think Ant -diagnositcs gives the interesting informarmation but not in the
build executing state and is static in nature.
Thanks in advance for thoughts!
Regards,
Ravi.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
AW: Showing current classpath Ant is using in Build executing state
Posted by Rainer Noack <ra...@noacks.net>.
... for some deeper information take a look at the <classloaderreport> task
at
http://enitsys.sourceforge.net/ant-classloadertask/
cheers
Rainer
-----Ursprüngliche Nachricht-----
Von: glenn opdycke-hansen [mailto:glennoph@gmail.com]
Gesendet: Sonntag, 7. Oktober 2007 02:21
An: Ant Users List; ravi.aroy@gmail.com
Betreff: Re: Showing current classpath Ant is using in Build executing state
I would echo the properties, perhaps logging to a file.
<echoproperties/>
---glenn
On 10/6/07, Ravi Roy <ra...@gmail.com> wrote:
>
> Hi All,
>
> In a scenario, where build is executing how I can see / log the current
> classpath of this build, which Ant is relying to build the project ?
> I think Ant -diagnositcs gives the interesting informarmation but not in
> the
> build executing state and is static in nature.
>
> Thanks in advance for thoughts!
>
> Regards,
> Ravi.
>
>
>
>
>
> ---------------------------------------------------------------------
> 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
Re: Showing current classpath Ant is using in Build executing state
Posted by glenn opdycke-hansen <gl...@gmail.com>.
I would echo the properties, perhaps logging to a file.
<echoproperties/>
---glenn
On 10/6/07, Ravi Roy <ra...@gmail.com> wrote:
>
> Hi All,
>
> In a scenario, where build is executing how I can see / log the current
> classpath of this build, which Ant is relying to build the project ?
> I think Ant -diagnositcs gives the interesting informarmation but not in
> the
> build executing state and is static in nature.
>
> Thanks in advance for thoughts!
>
> Regards,
> Ravi.
>
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>
>