11-30-2013 05:34 AM
<?xml version="1.0"?>
<project name="ASP AMP Build File" default="package-amp" basedir=".">
<property name="project.dir" value="."/>
<property name="alfresco.dir" value="C:/Tools/Dev/AlfrescoExtention/alfresco-community-sdk-2.1.0R1"/>
<property name="build.dir" value="${project.dir}/build"/>
<property name="config.dir" value="${project.dir}/config"/>
<property name="jar.file" value="${build.dir}/lib/alfresco-asp.jar"/>
<property name="amp.file" value="${build.dir}/dist/alfresco-asp.amp"/>
<target name="mkdirs">
<mkdir dir="${build.dir}/dist" />
<mkdir dir="${build.dir}/lib" />
</target>
<path id="class.path">
<dirset dir="${build.dir}" />
<fileset dir="${alfresco.dir}/lib" includes="**/*.jar"/>
<fileset dir="${project.dir}/lib" includes="**/*.jar"/>
</path>
<target name="compile" >
<javac debug="on" classpathref="class.path" srcdir="${project.dir}/source/java" destdir="${build.dir}/classes" />
</target>
<target name="package-jar" depends="compile">
<jar destfile="${jar.file}" >
<fileset dir="${build.dir}/classes" excludes="**/custom*,**/*Test*" includes="**/*.class" />
</jar>
</target>
<target name="package-amp" depends="mkdirs, package-jar" description="Package the Module" >
<echo>Packaging up AMP ${amp.file}</echo>
<zip destfile="${amp.file}" >
<fileset dir="${project.dir}/source/" includes="web/**/*.*" />
<fileset dir="${project.dir}/source/" includes="web/**/**/*.*" />
<fileset dir="${project.dir}/" includes="WEB-INF/faces-config-custom.xml" />
<fileset dir="${project.dir}/" includes="WEB-INF/repo.tld" />
<fileset dir="${project.dir}/" includes="index.jsp" />
<fileset dir="${project.dir}/" includes="WEB-INF/web.xml" />
<fileset dir="${project.dir}/" includes="file-mapping.properties" />
<fileset dir="${project.dir}/" includes="lib/*.jar" />
<fileset dir="${project.dir}/build" includes="lib/*.jar" />
<fileset dir="${project.dir}" includes="config/**/*.*" excludes="**/module.properties,**/asp-repository.properties,**/asp-config.xml" />
<fileset dir="${project.dir}/config/alfresco/module/ASP amp" includes="module.properties" />
</zip>
</target>
<target name="update-war" depends="package-amp" description="Update the WAR file. Set -Dwar.file=…" >
<echo>Installing asp AMP into WAR ${war.file}</echo>
<java dir="." fork="true" classname="org.alfresco.repo.module.tool.ModuleManagementTool">
<classpath refid="class.path" />
<arg line="install ${amp.file} ${war.file} -force -review -verbose -nobackup -nocopy "/>
</java>
</target>
</project>
12-02-2013 09:50 AM
12-07-2013 10:06 AM
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.