Changeset 15305
- Timestamp:
- 2008-04-30T15:50:01+12:00 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
other-projects/trunk/gs3-webservices-democlient/build.xml
r15242 r15305 19 19 <property name="fedorags3.src" value="${fedorags3.rootdir}/org" /> 20 20 <property name="build" value="${basedir}/build" /> 21 <property name=" bin" value="${basedir}/bin" />21 <property name="dist" value="${basedir}/dist" /> 22 22 <property name="QBRdata.rel.path" value="org/greenstone/gs3client/data" /> 23 23 <property name="dlservices.rel.path" value="org/greenstone/gs3client/dlservices" /> … … 27 27 <property name="download.zip.name" value="gs3_webservices_democlient" /> 28 28 <property name="log4j.propFile" value="log4j.properties" /> 29 <property name="zip.excludes" value="bin/**,logs/**,gs3democlient.properties,${log4j.propFile}" /> 29 <property name="zip.excludes" value="dist/**,logs/**,gs3democlient.properties" /> 30 30 31 <!-- ============ project classpath: everything in the lib folder =================== --> 31 32 <path id="project.classpath"> … … 41 42 <echo>- ant compile-demo-client</echo> 42 43 <echo> for compiling the democlient</echo> 43 <echo>- fedoraGS3jar</echo>44 <echo>- ant fedoraGS3jar</echo> 44 45 <echo> for generating the fedoraGS3.jar dependency file</echo> 45 <echo>- QBRdatajar</echo>46 <echo>- ant QBRdatajar</echo> 46 47 <echo> for generating the QBRdata.jar dependency file</echo> 47 <echo>- generate-download</echo>48 <echo>- ant make-dist</echo> 48 49 <echo> for generating the zip/gzip/bzip file of the project</echo> 49 50 <echo>- ant clean-democlient</echo> … … 69 70 </target> 70 71 71 <target name="generate-download" description="Generates the zip file of the lib and src folders and the executable ${exec.jar.name} file" depends="get-ziptype,ensure-exec-jar" if="zip.type"> 72 <mkdir dir="${bin}" /> 72 <target name="make-dist" description="Generates the zip file of the lib and src folders and the executable ${exec.jar.name} file" depends="get-zipformat,ensure-exec-jar" if="zip.type"> 73 <mkdir dir="${dist}" /> 74 <echo>zip.type=${zip.type}</echo> 73 75 <antcall target="create-${zip.type}"/> 74 76 </target> … … 103 105 <fileset dir="logs"/> 104 106 <fileset file="${log4j.propFile}"/> 105 <fileset file="${ bin}/${download.zip.name}.tar"/>106 <fileset file="${ bin}/${download.zip.name}.tar.gz"/>107 <fileset file="${ bin}/${download.zip.name}.zip"/>108 <fileset file="${ bin}/${download.zip.name}.tar.bz2"/>107 <fileset file="${dist}/${download.zip.name}.tar"/> 108 <fileset file="${dist}/${download.zip.name}.tar.gz"/> 109 <fileset file="${dist}/${download.zip.name}.zip"/> 110 <fileset file="${dist}/${download.zip.name}.tar.bz2"/> 109 111 </delete> 110 112 </target> … … 166 168 </target> 167 169 168 <!-- User input for generating compressed output file for one of the chosen file types (zip, gzip, or bzip)--> 169 <target name="create-gzip" if="gzip" description="User chose to create a tar.gz file of the project"> 170 <tar destfile="${bin}/${download.zip.name}.tar" basedir="${basedir}" excludes="${zip.excludes}" /> 171 <gzip destfile="${bin}/${download.zip.name}.tar.gz" src="${bin}/${download.zip.name}.tar" /> 172 <delete file="${bin}/${download.zip.name}.tar"/> 173 </target> 174 175 <target name="create-bzip" if="bzip" description="User chose to create a tar.bz2 file of the project"> 176 <tar destfile="${bin}/${download.zip.name}.tar" basedir="${basedir}" excludes="${zip.excludes}"/> 177 <bzip2 destfile="${bin}/${download.zip.name}.tar.bz2" src="${bin}/${download.zip.name}.tar"/> 178 <delete file="${bin}/${download.zip.name}.tar"/> 179 </target> 180 181 <target name="create-zip" if="zip" description="User chose to create a zip file of the project"> 182 <zip destfile="${bin}/${download.zip.name}.zip" basedir="${basedir}" excludes="${zip.excludes}"/> 183 </target> 184 185 <target name="get-ziptype"> 170 <!-- User input for generating compressed output file for one of the chosen file types. A choice of zip, tar.gz (tar gzip), or tar.bz2 (tar bzip)--> 171 <target name="create-targzip" if="zip.type" description="User chose to create a tar.gz file of the project"> 172 <tar destfile="${dist}/${download.zip.name}.tar.gz" basedir="${basedir}" compression="gzip" excludes="${zip.excludes}" /> 173 </target> 174 175 <target name="create-tarbzip" if="zip.type" description="User chose to create a tar.bz2 file of the project"> 176 <tar destfile="${dist}/${download.zip.name}.tar.bz2" basedir="${basedir}" compression="bzip2" excludes="${zip.excludes}" /> 177 </target> 178 179 <target name="create-zip" if="zip.type" description="User chose to create a zip file of the project"> 180 <zip basedir="${basedir}" destfile="${dist}/${download.zip.name}.zip" 181 excludes="${zip.excludes}" /> 182 </target> 183 184 <target name="get-zipformat"> 186 185 <!--<input addproperty="zip.type" validargs="zip,gzip,bzip">--><!-- doesn't work with default value--> 187 <input addproperty="zip. type" defaultvalue="zip">What type of compressed output file do you want to generate.188 Choose from zip, gzip (for tar.gz), bzip (tar.bz2)? 186 <input addproperty="zip.format" defaultvalue="zip">What type of compressed output file do you want to generate? 187 Type one of: zip, tar.gz, tar.bz2 189 188 Press enter for default: zip /></input> 190 189 <echo>You chose output file type: ${zip.type}</echo> 191 <condition property="gzip"> 192 <equals arg1="gzip" arg2="${zip.type}"/> 193 </condition> 194 <condition property="zip"> 195 <equals arg1="zip" arg2="${zip.type}"/> 196 </condition> 197 <condition property="bzip"> 198 <equals arg1="bzip" arg2="${zip.type}"/> 199 </condition> 190 <condition property="zip.type" value="targzip"> 191 <equals arg1="tar.gz" arg2="${zip.format}"/> 192 </condition> 193 <condition property="zip.type" value="zip"> 194 <equals arg1="zip" arg2="${zip.format}"/> 195 </condition> 196 <condition property="zip.type" value="tarbzip"> 197 <equals arg1="tar.bz2" arg2="${zip.format}"/> 198 </condition> 199 <echo>zip.type=${zip.type}</echo> 200 200 </target> 201 201 </project>
Note:
See TracChangeset
for help on using the changeset viewer.