Ignore:
Timestamp:
2008-03-06T14:08:49+13:00 (16 years ago)
Author:
oranfry
Message:

lots of work on wirk3

File:
1 edited

Legend:

Unmodified
Added
Removed
  • release-kits/wirk3/ant-scripts/init.xml

    r15023 r15053  
    185185        <echo level="info">Determining the branch path...</echo>
    186186        <if>
    187             <bool><equals arg1="trunk" arg2="${version}"/></bool>
    188             <property name="branch.path" value="trunk"/>
    189         </if>
    190 
    191         <if>
    192187            <bool><not><isset property="branch.path"/></not></bool>
    193188            <fail>You have not specified a branch path where code will come from in the repository</fail>
     
    196191        <echo level="info">Branch Path: ${branch.path}</echo>
    197192        <echo level="info"/>
    198 
    199         <!-- check branches exist -->
    200         <property name="svn.greenstone3" value="${svn.root}/greenstone3/${branch.path}"/>
    201         <property name="svn.gsdl" value="${svn.root}/gsdl/${branch.path}"/>
    202         <property name="svn.gli" value="${svn.root}/gli/${branch.path}"/>
    203         <property name="svn.indexers" value="${svn.root}/indexers/${branch.path}"/>
    204         <property name="svn.documentation" value="${svn.root}/documentation/${branch.path}"/>
    205 
    206         <!-- greenstone3 branch -->
    207         <echo level="info">Checking that ${svn.greenstone3} exists...</echo>
    208 
    209         <!-- try to put the html index of the location into the temp file -->
    210         <setloglevel level="error"/>
    211         <try>
    212             <get src="${svn.greenstone3}" dest="${temp.file}"/>
    213             <catch>
    214                 <echo level="error">No, it does not exist</echo>
    215                 <property name="svn.greenstone3.unavailable" value="true"/>
    216             </catch>
    217         </try>
    218         <setloglevel level="info"/>
    219         <if>
    220             <bool><not><istrue value="${svn.greenstone3.unavailable}"/></not></bool>
    221             <echo level="info">Yes, it exists</echo>
    222         </if>
    223 
    224         <!-- gsdl branch -->
    225         <echo level="info">Checking that ${svn.gsdl} exists...</echo>
    226         <setloglevel level="error"/>
    227         <try>
    228             <get src="${svn.gsdl}" dest="${temp.file}"/>
    229             <catch>
    230                 <echo level="error">No, it does not exist</echo>
    231                 <property name="svn.gsdl.unavailable" value="true"/>
    232             </catch>
    233         </try>
    234         <setloglevel level="info"/>
    235         <if>
    236             <bool><not><istrue value="${svn.gsdl.unavailable}"/></not></bool>
    237             <echo level="info">Yes, it exists</echo>
    238         </if>
    239 
    240 
    241         <!-- gli branch -->
    242         <echo level="info">Checking that ${svn.gli} exists...</echo>
    243         <!-- try to put the  html index of the location into the temp file -->
    244         <setloglevel level="error"/>
    245         <try>
    246             <get src="${svn.gli}" dest="${temp.file}"/>
    247             <catch>
    248                 <echo level="error">No, does not exist</echo>
    249                 <property name="svn.gli.unavailable" value="true"/>
    250             </catch>
    251         </try>
    252         <setloglevel level="info"/>
    253         <if>
    254             <bool><not><istrue value="${svn.gli.unavailable}"/></not></bool>
    255             <echo level="info">Yes, it exists</echo>
    256         </if>
    257 
    258 
    259         <!-- indexers branch -->
    260         <echo level="info">Checking that ${svn.indexers} exists...</echo>
    261         <!-- try to put the  html index of the location into the temp file -->
    262         <setloglevel level="error"/>
    263         <try>
    264             <get src="${svn.indexers}" dest="${temp.file}"/>
    265             <catch>
    266                 <echo level="error">No, it does not exist</echo>
    267                 <property name="svn.indexers.unavailable" value="true"/>
    268             </catch>
    269         </try>
    270         <setloglevel level="info"/>
    271         <if>
    272             <bool><not><istrue value="${svn.indexers.unavailable}"/></not></bool>
    273             <echo level="info">Yes, it exists</echo>
    274         </if>
    275 
    276         <!-- documentation branch -->
    277         <echo level="info">Checking that ${svn.documentation} exists...</echo>
    278         <!-- try to put the  html index of the location into the temp file -->
    279         <setloglevel level="error"/>
    280         <try>
    281             <get src="${svn.documentation}" dest="${temp.file}"/>
    282             <catch>
    283                 <echo level="error">No, it does not exist</echo>
    284                 <property name="svn.documentation.unavailable" value="true"/>
    285             </catch>
    286         </try>
    287         <setloglevel level="info"/>
    288         <if>
    289             <bool><not><istrue value="${svn.documentation.unavailable}"/></not></bool>
    290             <echo level="info">Yes, it exists</echo>
    291         </if>
    292 
    293 
    294         <!-- clean up the temp file -->
    295         <setloglevel level="error"/>
    296         <delete file="${temp.file}"/>
    297         <setloglevel level="info"/>
    298 
    299 
    300         <!-- fail if some branches were missing -->
    301         <if>
    302             <bool>
    303                 <or>
    304                     <istrue value="${svn.greenstone3.unavailable}"/>
    305                     <istrue value="${svn.gsdl.unavailable}"/>
    306                     <istrue value="${svn.gli.unavailable}"/>
    307                     <istrue value="${svn.indexers.unavailable}"/>
    308                     <istrue value="${svn.documentation.unavailable}"/>
    309                 </or>
    310             </bool>
    311             <fail>Some branches do not exist, or you are unable to access them from where you are. Please review the list above and create any branches that are missing, or run this script from somewhere with access to the repository.</fail>
    312             <else>
    313                 <echo level="info">All exist</echo>
    314             </else>
    315         </if>
     193       
     194        <!-- check branch.revision -->
     195        <echo level="info">Determining the branch revision...</echo>
     196        <if>
     197            <bool><not><isset property="branch.revision"/></not></bool>
     198            <property name="branch.revision" value="HEAD"/>
     199            <!--<echo level="info">No branch revision specified, defaulting to HEAD</echo>-->
     200        </if>
     201
     202        <echo level="info">Branch Revision: ${branch.revision}</echo>
     203        <echo level="info"/>
    316204
    317205    </target>
Note: See TracChangeset for help on using the changeset viewer.