forked from roskakori/tratihubis
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.xml
87 lines (81 loc) · 3.28 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
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
<project name="tratihubis" default="sdist" basedir=".">
<description>Buildfile for tratihubis</description>
<target name="sdist" description="build source distribution">
<!-- Delete Mac OS X Finder cache files. -->
<delete>
<fileset defaultexcludes="false" dir="." includes="**/.DS_Store" />
</delete>
<exec executable="python" failonerror="true">
<arg value="setup.py" />
<arg value="sdist" />
<arg value="--formats=zip" />
</exec>
</target>
<target name="sdist_upload" description="build source distribution">
<!-- Delete Mac OS X Finder cache files. -->
<delete>
<fileset defaultexcludes="false" dir="." includes="**/.DS_Store" />
</delete>
<exec executable="python" failonerror="true">
<arg value="setup.py" />
<arg value="sdist" />
<arg value="--formats=zip" />
<arg value="upload" />
</exec>
</target>
<target name="test" description="run test suite">
<exec executable="nosetests" failonerror="false">
<arg value="--with-coverage" />
<arg value="--with-doctest" />
<arg value="--with-xunit" />
<arg value="--cover-erase" />
<arg value="--exclude" />
<!-- TODO: Implement automatic test cases for web interface. -->
<arg value=".*setup.*" />
</exec>
<exec executable="coverage" failonerror="true">
<arg value="xml" />
</exec>
</target>
<target name="clean" description="clean up">
<!-- Delete files and folders generated by target "sdist". -->
<exec executable="python" failonerror="true">
<arg value="setup.py" />
<arg value="clean" />
</exec>
<!-- Delete various generated files. -->
<delete>
<fileset dir="." includes="**/*.pyc, **/*.pyo, **/*$py.class" />
<fileset dir="." includes="coverage.xml, nosetests.xml, pep8.txt" />
</delete>
<delete dir="build" />
</target>
<target name="pep8" description="build pep8 violations report">
<echo message="build pep8 violations report" />
<exec executable="pep8">
<!--
Note: We do not use failonerror="true" because any violations results in an exit code
of 1, which would result in the whole build to be considered failed.
-->
<arg value="--ignore" />
<arg value="E126,E127,E128" />
<arg value="--max-line-length=119" />
<arg file="setup.py" />
<arg file="tratihubis.py" />
<arg file="test/test_tratihubis.py" />
<redirector output="pep8.txt" />
</exec>
</target>
<target name="autopep8" description="clean up pep8 violations">
<echo message="clean up pep8 violations" />
<exec executable="autopep8" failonerror="true">
<arg value="--in-place" />
<arg value="--ignore" />
<arg value="E126,E127,E128,E501" />
<arg file="setup.py" />
<arg file="tratihubis.py" />
<arg file="test/test_tratihubis.py" />
<redirector output="pep8.txt" />
</exec>
</target>
</project>