forrest-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From je...@apache.org
Subject cvs commit: xml-forrest build.xml
Date Sat, 16 Nov 2002 12:45:32 GMT
jefft       2002/11/16 04:45:32

  Modified:    .        build.xml
  Log:
  Add hackery to fix linefeeds in scripts before zipping the source distribution
  
  Revision  Changes    Path
  1.47      +33 -3     xml-forrest/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/xml-forrest/build.xml,v
  retrieving revision 1.46
  retrieving revision 1.47
  diff -u -r1.46 -r1.47
  --- build.xml	16 Nov 2002 10:49:22 -0000	1.46
  +++ build.xml	16 Nov 2002 12:45:32 -0000	1.47
  @@ -76,19 +76,49 @@
       <delete dir="${build.dir}"/>
     </target>
   
  -  <target name="release-dist-source" depends="init"
  +  <target name="release-dist-src" depends="init"
       description="Makes a source release distribution">
       <mkdir dir="${dist.dir}"/>
  +
  +    <!-- Hackery to fix linefeeds and permissions before zipping -->
  +    <patternset id="scripts">
  +      <include name="**/*.bat"/>
  +      <include name="**/*.sh"/>
  +      <include name="**/ant"/>
  +      <include name="**/forrest"/>
  +    </patternset>
  +
  +    <patternset id="noscripts">
  +      <exclude name="**/*.bat"/>
  +      <exclude name="**/*.sh"/>
  +      <exclude name="**/ant"/>
  +      <exclude name="**/forrest"/>
  +    </patternset>
  +
  +    <property name="tmp-scripts" location="${build.dir}/tmp/scripts"/>
  +    <mkdir dir="${tmp-scripts}"/>
  +    <copy todir="${tmp-scripts}">
  +      <fileset dir=".">
  +        <patternset refid="scripts"/>
  +      </fileset>
  +    </copy>
  +    <fixcrlf eol="crlf" srcdir="${tmp-scripts}" includes="**/*.bat"/>
  +    <fixcrlf eol="lf" srcdir="${tmp-scripts}" excludes="**/*.bat"/>
  +    <chmod dir="${tmp-scripts}" perm="ugo+rx" excludes="**/*.bat"/> 
  +
       <property name="release-name-src" value="${name}-${version}-src"/>
       <zip
         file="${dist.dir}/${release-name-src}.zip" >
         <zipfileset dir="." prefix="${release-name-src}">
           <exclude name="build/**"/>
  +        <patternset refid="noscripts"/>
         </zipfileset>
  -      <zipfileset dir="etc"  prefix="${release-name-src}" includes="RELEASE-NOTES-${version}.txt"/>
  +      <zipfileset prefix="${release-name-src}" dir="${tmp-scripts}"/>
  +      <zipfileset prefix="${release-name-src}" dir="etc" includes="RELEASE-NOTES-${version}.txt"/>
       </zip>
     </target>
   
  +
     <target name="release-dist-bin" depends="init, dist-shbat" 
       description="Makes a binary release distribution">
       <property name="release-name-bin" value="${name}-${version}-bin"/>
  @@ -102,7 +132,7 @@
   
     <target name="release-dist" 
       description="Makes source and binary release distributions"
  -    depends="release-dist-bin, release-dist-source"/>
  +    depends="release-dist-bin, release-dist-src"/>
   
   
   
  
  
  

Mime
View raw message