·  ANT – Tags – <property/>

 

- Info:

  - Property tag is used to define variables.

  - Variable can be defined inside the ANT script or in a separate file.

  - When defining path inside file use '/'.

 

- Example:

  - Create ANT Script Test.xml

 

    Test.xml

    <?xml version="1.0" encoding="UTF-8"?>

    

    <project name="MyAntProject" default="default" basedir=".">

    

      <property name  = "first" 

                value = "First line."/>

    

      <property file  = "Test.properties"/>

    

      <target   name  = "default">

        <echo message="${first} ${second} ${third}"/>

      </target>   

        

    </project>

 

    Test.properties

    second = Second line.

    third  = Third line.