You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Carsten Ziegeler <cz...@s-und-n.de> on 2003/02/25 14:50:27 UTC

Removing ant properties from java code [was: Re: Javac task design problems]

Is anyone against removing the use of the ant properties
from Constants.java? This will avoid copying and filtering
the java sources (at least for most parts).

Carsten 

Carsten Ziegeler 
Open Source Group, S&N AG


Re: Removing ant properties from java code [was: Re: Javac task design problems]

Posted by Bernhard Huber <be...@a1.net>.
Carsten Ziegeler wrote:

>Is anyone against removing the use of the ant properties
>from Constants.java? This will avoid copying and filtering
>the java sources (at least for most parts).
>
+1, as building is going to be more easy

Alternativly what about the solution:
1. rename Constants.java to Constants.java.templ, and
  put Constants.java.templ under CVS control only
2. copy with filtering from Constants.java.templ to Constants.java into 
SAME directory

that might be a solution for keeping the java-properties, and increasing
build-time.

regards bernhard



RE: Removing ant properties from java code [was: Re: Javac task design problems]

Posted by Carsten Ziegeler <cz...@s-und-n.de>.
Berin Loritsch wrote:
> 
> Carsten Ziegeler wrote:
> > Is anyone against removing the use of the ant properties
> > from Constants.java? This will avoid copying and filtering
> > the java sources (at least for most parts).
> 
> I am +1.
> 
> Question though (a little off topic):
> 
> Sometimes it is useful to access properties that are only
> determinable at build time.  Is there any way to dynamically
> append or create a properties file/change an xconf file?
> 
If I understand you correctly, our own XConfTool ant task
does exactly this. It adds/removes entries to/from the xconf
and the sitemap.

Carsten

Re: Removing ant properties from java code [was: Re: Javac task design problems]

Posted by Berin Loritsch <bl...@apache.org>.
Carsten Ziegeler wrote:
> Is anyone against removing the use of the ant properties
> from Constants.java? This will avoid copying and filtering
> the java sources (at least for most parts).

I am +1.

Question though (a little off topic):

Sometimes it is useful to access properties that are only
determinable at build time.  Is there any way to dynamically
append or create a properties file/change an xconf file?

That would remove any remaining needs to copy files that I
could possibly think of.

Oh, also there are a couple places in Avalon, like for the
DataSource code where only the "dynamic" files are copied,
but they are included in the compiled source.  I think
it uses something like a <fileset> directive inside the
<javac>.  That way *only* the files that need filtering are
ever moved around, and the source files can be compiled
where they are (for the most part).