An example how to use the nativ2ascii-ant-task:

    <target name="copy_resources" depends="compile">
       <!-- copies all non-java-files (especially class and
ApplicationResources) to targetdir -->
        <copy todir="${targetdir}">
            <fileset dir="${sourcedir}">
                <exclude name="**/*.java"/>
            </fileset>
        </copy>
        <!-- This converts the human-readable utf8 into java-readable UTF8 -->
        <native2ascii encoding="UTF-8" src="${targetdir}" dest="${targetdir}"
                   includes="**/*.properties_src" ext=".properties" />
         <delete>
            <fileset dir="${targetdir}" includes="**/*.properties_src"/>
          </delete>

     </target>

Name your ApplicationResource-files ApplicationResources.properties_src in
your source-directory.

1. properties_src-files get copied to target-directory
2. native2ascii converts them and renames the extension to ".properties"
3. unneeded properties_src are deleted from target-directory


-- 
View this message in context: 
http://www.nabble.com/native2ascii--in-build.xml-tp17818914p24371730.html
Sent from the Ant - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to