-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathbuild.xml
More file actions
52 lines (41 loc) · 1.49 KB
/
Copy pathbuild.xml
File metadata and controls
52 lines (41 loc) · 1.49 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
<?xml version="1.0" encoding="UTF-8"?>
<project name="Mobitex Sender" default="build">
<target name="build" depends="prepare,phpunit" />
<target name="clean" description="Cleanup build artifacts">
<delete dir="${basedir}/build/api" />
<delete dir="${basedir}/build/code-browser" />
<delete dir="${basedir}/build/coverage" />
<delete dir="${basedir}/build/logs" />
</target>
<target name="prepare" depends="clean,composer" description="Prepare for build">
<mkdir dir="${basedir}/build/api" />
<mkdir dir="${basedir}/build/code-browser" />
<mkdir dir="${basedir}/build/coverage" />
<mkdir dir="${basedir}/build/logs" />
</target>
<target name="composer" description="updates composer libs">
<exec dir="${basedir}" executable="sh" failonerror="true">
<arg value="-c" />
<arg value="curl -s http://getcomposer.org/installer | php" />
</exec>
<exec executable="php" failonerror="true">
<arg line="${basedir}/composer.phar install --no-ansi --no-interaction" />
</exec>
</target>
<target name="lint" description="Perform syntax check of sourcecode files">
<apply executable="php" failonerror="true">
<arg value="-l" />
<fileset dir="${basedir}/app">
<include name="**/*.php" />
<modified />
</fileset>
<fileset dir="${basedir}/tests">
<include name="**/*.php" />
<modified />
</fileset>
</apply>
</target>
<target name="phpunit" description="Run unit tests with PHPUnit">
<exec executable="phpunit" failonerror="true" />
</target>
</project>