root / branches / v2_0_0_prep / extensions / org.gvsig.mkmvnproject / build.xml @ 38548
History | View | Annotate | Download (2.58 KB)
1 |
<project name="gvSIG-build-config" default="mvn-install" xmlns:artifact="antlib:org.apache.maven.artifact.ant"> |
---|---|
2 |
|
3 |
<property name="maven.folder" |
4 |
location="${basedir}/src/main/resources/maven" /> |
5 |
|
6 |
<!-- Maven ant tasks registration -->
|
7 |
<path id="maven-ant-tasks.classpath" |
8 |
path="${maven.folder}/lib/maven-ant-tasks-2.0.10.jar" /> |
9 |
<typedef resource="org/apache/maven/artifact/ant/antlib.xml" |
10 |
uri="antlib:org.apache.maven.artifact.ant" |
11 |
classpathref="maven-ant-tasks.classpath" /> |
12 |
|
13 |
<!-- Maven targets -->
|
14 |
<macrodef name="maven"> |
15 |
<attribute name="arg" /> |
16 |
<sequential>
|
17 |
<echo>mvn @{arg}</echo> |
18 |
<artifact:mvn mavenHome="${maven.folder}" fork="true" |
19 |
failonerror="true" maxmemory="256M"> |
20 |
<arg line="@{arg}" /> |
21 |
<jvmarg value="-XX:MaxPermSize=64M" /> |
22 |
</artifact:mvn>
|
23 |
</sequential>
|
24 |
</macrodef>
|
25 |
|
26 |
<!-- Utility targets -->
|
27 |
<target name="cancel"> |
28 |
<fail>User canceled</fail> |
29 |
</target>
|
30 |
|
31 |
<target name="mvn-clean" description="Cleans all artifacts"> |
32 |
<maven arg="clean" /> |
33 |
</target>
|
34 |
|
35 |
<target name="mvn-compile" description="Compiles all source code"> |
36 |
<maven arg="compile" /> |
37 |
</target>
|
38 |
|
39 |
<target name="mvn-test" description="Launches unit tests"> |
40 |
<maven arg="test" /> |
41 |
</target>
|
42 |
|
43 |
<target name="mvn-install" description="Compiles and installs"> |
44 |
<maven arg="install" /> |
45 |
</target>
|
46 |
|
47 |
<target name="mvn-install-ignore-tests" description="Compiles and installs and ignore tests"> |
48 |
<maven arg="install -Dmaven.test.failure.ignore" /> |
49 |
</target>
|
50 |
|
51 |
<target name="mvn-install-without-tests" |
52 |
description="Compiles and installs without launching tests"> |
53 |
<maven arg="-Dmaven.test.skip=true install" /> |
54 |
</target>
|
55 |
|
56 |
<target name="mvn-reinstall" |
57 |
description="Performs a clean install"> |
58 |
<maven arg="clean install" /> |
59 |
</target>
|
60 |
|
61 |
<target name="mvn-reinstall-without-tests" |
62 |
description="Performs a clean install without launching tests"> |
63 |
<maven arg="-Dmaven.test.skip=true clean install" /> |
64 |
</target>
|
65 |
|
66 |
<target name="mvn-deploy" |
67 |
description="Compiles, installs and deploys"> |
68 |
<maven arg="deploy" /> |
69 |
</target>
|
70 |
|
71 |
<target name="mvn-deploy-release" |
72 |
description="Compiles, installs and deploys for release"> |
73 |
<maven arg="-P release deploy" /> |
74 |
</target>
|
75 |
|
76 |
<target name="mvn-eclipse-clean" |
77 |
description="Cleans the maven generated eclipse project files"> |
78 |
<maven arg="eclipse:clean" /> |
79 |
</target>
|
80 |
|
81 |
<target name="mvn-eclipse-eclipse" |
82 |
description="Generates an eclipse project configuration from the pom.xml"> |
83 |
<maven arg="eclipse:eclipse" /> |
84 |
</target>
|
85 |
|
86 |
<target name="mvn-site" |
87 |
description="Generates the project site documentation"> |
88 |
<maven arg="site" /> |
89 |
</target>
|
90 |
</project>
|