forked from webburza/sylius-google-ecommerce-bundle
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
60 lines (51 loc) · 2.36 KB
/
build.xml
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
<?xml version="1.0" encoding="UTF-8"?>
<project name="sylius-google-ecommerce-bundle" default="release" basedir=".">
<property name="vendorDir" value="${project.basedir}/vendor" override="true"/>
<property name="vendorBinDir" value="${vendorDir}/bin" override="true"/>
<property name="rootDir" value="${project.basedir}" override="true"/>
<property name="binDir" value="${project.basedir}/bin" override="true"/>
<property name="srcDir" value="${project.basedir}/src" override="true"/>
<property name="testsDir" value="${project.basedir}/tests" override="true"/>
<property name="logsDir" value="${project.basedir}/build/logs" override="true"/>
<property name="phpmdFile" value="/Tests/phpmd.xml" override="true"/>
<target name="style">
<exec executable="${vendorBinDir}/php-cs-fixer" escape="true" passthru="true" checkreturn="true">
<arg line="fix --diff --dry-run -v"/>
</exec>
</target>
<target name="fix-style">
<exec executable="${vendorBinDir}/php-cs-fixer" escape="true" passthru="true">
<arg line="fix --diff -v"/>
</exec>
</target>
<target name="mess">
<exec executable="${vendorBinDir}/phpmd" escape="true" passthru="true" checkreturn="true">
<arg line="${rootDir}"/>
<arg line="text"/>
<arg line="${phpmdFile}"/>
<arg line="--strict"/>
<arg line="--exclude ${vendorDir},${testsDir}"/>
</exec>
</target>
<target name="copy-paste">
<exec executable="${vendorBinDir}/phpcpd" escape="true" passthru="true" checkreturn="true">
<arg line="${rootDir}"/>
<arg line="--fuzzy"/>
<arg line="--exclude vendor"/>
</exec>
</target>
<target name="test">
<exec executable="${vendorBinDir}/phpunit" escape="true" passthru="true" checkreturn="true"/>
</target>
<target name="test-coverage">
<exec executable="${vendorBinDir}/phpunit" escape="true" passthru="true" checkreturn="true">
<arg line=" --coverage-clover ${logsDir}/clover.xml"/>
</exec>
</target>
<target name="ci" depends="style,mess,copy-paste,test-coverage">
<echo message="Build complete!"/>
</target>
<target name="release" depends="fix-style,mess,copy-paste,test">
<echo message="Build complete!"/>
</target>
</project>