-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathbuild.xml
More file actions
60 lines (51 loc) · 2.65 KB
/
Copy pathbuild.xml
File metadata and controls
60 lines (51 loc) · 2.65 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<project name="cf-websocket-gateway" default="make" basedir=".">
<property name="java.home" value="env.JAVA_HOME"/>
<property name="cf.home" value="/Applications/Jrun4/servers/cfusion/cfusion-ear/cfusion-war/WEB-INF/cfusion"/>
<property name="cfusionjar" value="${cf.home}/lib/cfusion.jar"/>
<property file="version.properties"/>
<target name="make" depends="clean,compile,jar" description="The default: build everything."/>
<target name="make-dist" depends="clean,compile,jar" description="Packages up distro.">
<mkdir dir="${basedir}/dist"/>
<zip destfile="${basedir}/dist/${ant.project.name}-${engine}-${version}.zip">
<zipfileset dir="${basedir}/bin" includes="*.jar"/>
<zipfileset dir="${basedir}/lib" includes="*.jar"/>
<zipfileset dir="${basedir}" includes="LICENSE,README.md"/>
</zip>
</target>
<target name="install" depends="make,remove-files,copy-files" description="Builds everything and copies files to ColdFuison."/>
<target name="jar" description="Create the jar file.">
<jar destfile="${basedir}/bin/${ant.project.name}-${version}.jar">
<fileset dir="${basedir}/bin"/>
</jar>
</target>
<target name="clean" description="Remove compiled classes and jar.">
<delete dir="${basedir}/bin"/>
<delete dir="${basedir}/dist"/>
</target>
<target name="compile" description="Compile the java classes.">
<mkdir dir="${basedir}/bin"/>
<javac srcdir="${basedir}/src" destdir="${basedir}/bin" fork="true">
<classpath>
<pathelement location="${cfusionjar}"/>
<fileset dir="${basedir}/lib">
<include name="**/*.jar"/>
</fileset>
</classpath>
</javac>
</target>
<target name="remove-files" description="Removes the files from the ColdFusion server.">
<delete file="${cf.home}/gateway/lib/${ant.project.name}-${version}.jar" />
<delete file="${cf.home}/gateway/config/websocket.cfg" />
<delete file="${cf.home}/gateway/lib/netty-3.2.6.Final.jar" />
<delete file="${cf.home}/gateway/lib/webbit-0.3.0.jar" />
</target>
<target name="copy-files" description="Copies the files to the ColdFusion server.">
<copy file="${basedir}/bin/${ant.project.name}-${version}.jar" todir="${cf.home}/gateway/lib"/>
<copy file="${basedir}/config/websocket.cfg" todir="${cf.home}/gateway/config"/>
<copy todir="${cf.home}/gateway/lib">
<fileset dir="${basedir}/lib">
<include name="**/*.jar"/>
</fileset>
</copy>
</target>
</project>