Try ISO-8859-1 as your encoding... Someone I work with was attempting to use property files with a similar issue (but directly within Java). He used the ISO-8859-1 encoding and it fixed his problem...

On Fri, 27 May 2011, Rob J wrote:

So I'm having an issue with UTF-8 and property files.  Given the test
build.xml file:

<?xml version="1.0" encoding="utf-8"?>
<project name="test">
 <target name="foo">
   <loadproperties srcFile="foo.properties" encoding="utf-8"/>
   <echo file="test.txt" encoding="utf-8" message="${foo.property}"/>
 </target>
</project>

and the file foo.properties:

#foo.propert=Test ế
foo.property=Test \u1EBF

When I run ant (1.8.2) for this target and look in test.txt, I see:

Test ?

every time.  It is not interpreting the utf-8 character properly and therefore
is not putting it into my project properly.  I've tried both the raw utf-8
character in the file as well as the \uXXXX encoded version.  Both are the
same.

Can anyone point out where I'm going wrong with this?

thanks,
rob

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



Scot P. Floess             RHCT  (Certificate Number 605010084735240)
Chief Architect FlossWare  http://sourceforge.net/projects/flossware
                           http://flossware.sourceforge.net
                           https://github.com/organizations/FlossWare
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@ant.apache.org
For additional commands, e-mail: user-h...@ant.apache.org

Reply via email to