File: maven.xml

package info (click to toggle)
statsvn 0.7.0.dfsg-10
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, sid
  • size: 1,324 kB
  • sloc: xml: 5,959; java: 4,082; sh: 81; makefile: 5
file content (44 lines) | stat: -rw-r--r-- 1,361 bytes parent folder | download | duplicates (6)
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
<project xmlns:j="jelly:core" xmlns:u="jelly:util" xmlns:ant="jelly:ant"
	xmlns:maven="jelly:maven">

	<preGoal name="java:compile">
		<ant:filter token="VERSION" value="${pom.currentVersion}" />
		<ant:filter token="JAR" value="${maven.final.name}-full.jar" />
		<copy toDir="target/src" filtering="true" overwrite="true">
			<fileset dir="${pom.build.sourceDirectory}">
				<includes name="**/*" />
			</fileset>
		</copy>
		<path id="maven.compile.src.set" location="target/src" />
	</preGoal>

	<postGoal name="uberjar">
		<ant:move file="${maven.build.dir}/${maven.final.name}-uber.jar"
			toFile="${maven.build.dir}/${maven.final.name}-full.jar"
			overwrite="true" />
	</postGoal>

	<postGoal name="dist:build">
		<attainGoal name="uberjar" />
		<j:set var="distdir"
			value="${pom.getPluginContext('maven-dist-plugin').getVariable('maven.dist.dir')}" />
		<!-- Copy UberJars -->
		<ant:copy todir="${distdir}">
			<ant:fileset dir="${maven.build.dir}">
				<ant:include name="${maven.final.name}-full.jar" />
			</ant:fileset>
		</ant:copy>
	</postGoal>

	<goal name="dist:snapshot"
		description="Create a snapshot distribution">

		<maven:snapshot project="${pom}" />

		<j:set var="maven.final.name" value="${snapshotSignature}" />
		<ant:echo>Building snapshot JAR: ${maven.final.name}</ant:echo>

		<attainGoal name="dist" />
	</goal>

</project>