ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ian Kiigan" <>
Subject Using the Ant "filter" task with unicode files
Date Thu, 07 Nov 2002 12:50:12 GMT
Re: Problem using Ant filter task and accented characters
    etc in unicode files

Hi there Ant Users,

Quick question:

I'm using Ant 1.5 and doing something like this:

<copy todir="${src.filtered}">
  <fileset dir="${src.dir}">
    <include name="**/*.java"/>
  <filterset begintoken="%%" endtoken="%%">

And in the source of my application I do stuff like:

String titleStr = "%%mainmenu.title%%";

The idea being to replace tokens (as defined in a properties file)
in the source code of my application. It all works swimmingly for
English languages versions of my application, but when I use
accented characters for languages such as French or Italian, I
notice that the characters are NOT SUBSTITUTED CORRECTLY by the
filter task.

For example, a character such as "รน" (a lower case "u" with a
grav accent) is substituted as something else entirely (what looks
like "?" or similar, a capital A with a squiggle of some kind over it).

I've been using text editors that support Unicode (such as GVIM) so
I'd expected all of this to work fine. However it doesn't. Is there a
problem with the implementation of the filter task perhaps? Has anyone
else used the filter task for non-English unicode strings?

Thanks for any advice you might give,

Ian Kiigan

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message