-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathbuild.xml
More file actions
executable file
·117 lines (83 loc) · 3.96 KB
/
build.xml
File metadata and controls
executable file
·117 lines (83 loc) · 3.96 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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
<?xml version="1.0" encoding="UTF-8"?>
<project name="EventManager" default="compile">
<!-- update build properties -->
<propertyfile file="buildprops/build.properties">
<entry key="build.number" type="int" operation="+" value="1" pattern="00"/>
<entry key="build.date" type="date" pattern="EEEE MMM dd, yyyy" value="now"/>
<entry key="build.time" type="date" pattern="kk:mm:ss" value="now"/>
<entry key="build.timestamp" type="date" pattern="yyyy-MM-dd'T'HH:mm:ss" value="now"/>
<entry key="build.year" type="date" pattern="yyyy" value="now"/>
</propertyfile>
<!-- build properties -->
<property file="buildprops/build.properties"/>
<property file="buildprops/project.properties"/>
<property file="buildprops/unames.properties"/>
<property name="tmpdir" value="${java.io.tmpdir}/${build.projectName}/" />
<target name="runtests" description="Make output directories and run the MXUnit task">
<mkdir dir="${mxunit.output}" />
<taskdef name="mxunittask" classname="org.mxunit.ant.MXUnitAntTask" classpath="${mxunit.jar}"/>
<echo message="Runnig tests"/>
<mxunittask server="${server.host}" port="${server.port}"
defaultrunner="/mxunit/runner/HttpAntRunner.cfc"
verbose="true"
outputdir="testresults"
haltonfailure="true"
haltonerror="false">
<directory runner="${mxunit.httprunner}"
remoteMethod="run"
path="${test.component.path}"
packageName="${test.component.packagename}"
componentPath="${test.component.componentpath}"
recurse="true"
/>
</mxunittask>
</target>
<!--<target name="commit">
<echo level="info">Committing Cfem</echo>
<input message="SVN Commit Comment:" addproperty="commit.comment" defaultvalue="Periodic Commit From Ant Task" />
<taskdef resource="org/tigris/subversion/svnant/svnantlib.xml" classpathref="project.classpath"/>
<svn username="${svn.username}" password="${svn.password}">
<commit message="${commit.comment}" dir="${basedir}" recurse="true" />
</svn>
</target>-->
<target name="deploy">
<mkdir dir="${tmpdir}" />
<echo message="Copy to temp"/>
<copy todir="${tmpdir}">
<fileset dir="${basedir}/templates" includes="framework.properties"/>
<fileset dir="${basedir}/templates" includes="license.txt"/>
</copy>
<echo message="Replacing properties "/>
<replace dir="${tmpdir}">
<replacefilter token="@number" value="${build.number}"/>
<replacefilter token="@projectName" value="${build.projectName}"/>
<replacefilter token="@date" value="${build.date}"/>
<replacefilter token="@projectUrl" value="${build.projectUrl}"/>
<replacefilter token="@projectVersion" value="${build.projectVersion}"/>
<replacefilter token="@authorEmail" value="${build.authorEmail}"/>
<replacefilter token="@author" value="${build.author}"/>
<replacefilter token="@year" value="${build.year}"/>
</replace>
<echo message="Copy files"/>
<copy todir="${basedir}/com/andreacfm/cfem/" overwrite="true">
<fileset dir="${tmpdir}" includes="license.txt"/>
<fileset dir="${tmpdir}" includes="framework.properties"/>
</copy>
<delete dir="${tmpdir}"/>
</target>
<target name="updateDocs">
<mkdir dir="${tmpdir}" />
<echo message="Make docs"/>
<get src="http://localhost/cfeventmanager/colddoc/run.cfm" dest="${tmpdir}/docs_response.txt"/>
<replace dir="${basedir}/docs">
<replacefilter token="@number" value="${build.number}"/>
<replacefilter token="@projectName" value="${build.projectName}"/>
<replacefilter token="@date" value="${build.date}"/>
<replacefilter token="@projectVersion" value="${build.projectVersion}"/>
</replace>
<delete dir="${tmpdir}"/>
</target>
<target
name="compile"
depends="runtests,deploy,updateDocs" />
</project>