buildframework/helium/build.xml
changeset 217 0f5e3a7fb6af
parent 179 d8ac696cc51f
child 587 85df38eb4012
equal deleted inserted replaced
181:59bb7c4d6172 217:0f5e3a7fb6af
    27     
    27     
    28     <import file="build-jar.ant.xml"/>
    28     <import file="build-jar.ant.xml"/>
    29     <property name="build.drive" location="${env.TEMP}/helium/temp_drive"/>
    29     <property name="build.drive" location="${env.TEMP}/helium/temp_drive"/>
    30     <mkdir dir="${build.drive}/"/> 
    30     <mkdir dir="${build.drive}/"/> 
    31     
    31     
       
    32     <!-- @property helium.version
       
    33     @type string
       
    34     @scope private -->
    32     <property file="${helium.dir}/config/version.txt"/>
    35     <property file="${helium.dir}/config/version.txt"/>
    33     <property name="release.label" value="${helium.version}"/>
    36     <property name="release.label" value="${helium.version}"/>
       
    37 
       
    38     <!-- Override docs targets to do more for Helium. -->
       
    39     <target name="apidocs" depends="python-apidocs,java-apidocs,antdoclet,internal.docs.apidocs"/>
       
    40     <!-- Generate rst files for docs -->
       
    41     <target name="prep-textdocs" depends="overview-to-html,tools-rst-table,dependency-diagram,
       
    42         dependency-logs,release-diff,helium-user-graph,helium-prep-textdocs,internal.docs.prep-textdocs"/>
       
    43     <!-- generate all the user documentation for helium -->
       
    44     <target name="docs" depends="clean-doc-dir,database,apidocs,textdocs,add-policies-to-docs"/>
    34     
    45     
    35     <import file="helium.ant.xml"/>
    46     <import file="helium.ant.xml"/>
    36     <import file="tools/startup/antserver/antserver.ant.xml"/>
    47     <import file="tools/startup/antserver/antserver.ant.xml"/>
    37          
    48          
       
    49     
       
    50     
       
    51     
       
    52     <target name="must-property-comments">
       
    53         <!--<xslt in="${data.model.file}" out="${data.model.parsed}" style="${data.model.xsl}"/>-->
       
    54         <for param="ant.file">
       
    55             <fileset dir="${helium.dir}" includes="helium.ant.xml">
       
    56             </fileset>
       
    57             <sequential>     
       
    58                 <script language="jython">
       
    59 import re
       
    60 import java.io
       
    61 import org.dom4j
       
    62 import org.dom4j.io
       
    63 
       
    64 model = org.dom4j.io.SAXReader().read(java.io.File(project.getProperty("helium.dir") + '/build/datamodel.out'))
       
    65 
       
    66 user_props = model.selectNodes('//property[editStatus="must"]')
       
    67 indent = '    '
       
    68 out = open('required_properties.txt', 'w')
       
    69 for prop in user_props:
       
    70 #    print prop
       
    71     property_comment = indent + "&lt;!--* @property " + prop.elementTextTrim('name') + "\n"
       
    72     property_comment += indent + prop.elementTextTrim('description') + "\n"
       
    73     property_comment += indent + "@type " + prop.elementTextTrim('type') + "\n"
       
    74     property_comment += indent + "@editable required\n"
       
    75     property_comment += indent + "@scope public\n"
       
    76     property_comment += indent + "--&gt;\n\n"
       
    77     print property_comment
       
    78     out.write(property_comment)
       
    79 
       
    80 out.close()
       
    81                 </script>
       
    82             </sequential>
       
    83         </for>                               
       
    84     </target>
    38 </project>
    85 </project>
    39 
    86