Lokesh,

Maybe you don't comply with the rules java has for property files. These can be found in java language specifictaion, but also in Properties class javadoc:
http://docs.oracle.com/javase/7/docs/api/java/util/Properties.html

QUOTE
the input/output stream is encoded in ISO 8859-1 character encoding. Characters that cannot be directly represented in this encoding can be written using Unicode escapes as defined in section 3.3 of The Java^(TM) Language Specification;

Jarek

W dniu 04/21/2012 10:01 AM, Lokesh Jain pisze:
Hi,

I have a custom ant task which reads certain properties from build.properties and exports applications based on that.

<target name="exportSingleApp_internal" >
<taskdef classname="com.xxx.yyy.ant.tasks.ExportApplication" name="exportApplication" classpathref="proj.lib"/> <exportApplication applicationID = "${APPLICATION_GUID}" applicationVersion="${APPLICATION_VERSION}"
                          exportLocation="${APPLICATION_EXPORT_DIR}"/>
</target>

The property APPLICATION_GUID contains some accented chars such as "ÀÁÂ".

Now, when i execute this task on a Windows box, it seems to be working fine.

But on a CentOS box, the same property is read by the task program along with some junk unicode chars. Consequently, the strings do not match which affects some of the internal logic of the ant task.

Eg: If I set the APPLICATION_GUID property to HELLOÀÁÂ
The java program of the task reads the property as HELLOÃ\u0080Ã\u0081Ã\u0082

The $LANG env var on CentOS box is set to en_US.UTF-8.

I am not sure if this is an Ant issue. Any pointers would be helpful.

Regards,
Lokesh

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



Reply via email to