This repository was archived by the owner on Jan 5, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 108
Expand file tree
/
Copy pathprojecthosting.xml
More file actions
98 lines (82 loc) · 4.39 KB
/
Copy pathprojecthosting.xml
File metadata and controls
98 lines (82 loc) · 4.39 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
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
88
89
90
91
92
93
94
95
96
97
98
<project name="projecthosting" default="sample.projecthosting.build" basedir=".">
<!-- Path containing core.xml -->
<dirname property="build_dir" file="${ant.file.projecthosting}"/>
<import file="${build_dir}/core.xml"/>
<!-- ===================================================================== -->
<!-- Build GData Project Hosting library -->
<!-- ===================================================================== -->
<property name="gdata-projecthosting.jar"
value="${build.jars}/gdata-projecthosting-${projecthosting.spec.version}.jar"/>
<property name="sample.projecthosting.basedir" value="${build}/sample/projecthosting"/>
<property name="sample.projecthosting.src.home" value="${sample.projecthosting.basedir}"/>
<property name="sample.projecthosting.build.classes" value="${sample.projecthosting.basedir}/classes"/>
<property name="sample.projecthosting.build.lib" value="${sample.projecthosting.basedir}/lib"/>
<property name="sample.projecthosting.read.jar" value="${sample.projecthosting.build.lib}/ProjectHostingReadDemo.jar"/>
<property name="sample.projecthosting.write.jar" value="${sample.projecthosting.build.lib}/ProjectHostingWriteDemo.jar"/>
<property name="sample.projecthosting.read.main" value="sample.projecthosting.ProjectHostingReadDemo"/>
<property name="sample.projecthosting.write.main" value="sample.projecthosting.ProjectHostingWriteDemo"/>
<target name="sample.projecthosting.clean"
description="Delete old build and dist directories">
<delete dir="${sample.projecthosting.build.classes}"/>
</target>
<target name="sample.projecthosting.dependencies">
<antcall target="template.require.service.jar">
<param name="template.service.name" value="projecthosting"/>
<param name="template.service.version" value="${projecthosting.spec.version}"/>
</antcall>
</target>
<path id="sample.projecthosting.compile.classpath">
<path refid="build.service.core.classpath"/>
<pathelement location="${sample-util.jar}"/>
<pathelement location="${gdata-projecthosting.jar}"/>
</path>
<!-- samples build -->
<target name="sample.projecthosting.build"
depends="sample.projecthosting.dependencies,core.sample.core.util.build"
description="Create binary distribution">
<mkdir dir="${sample.projecthosting.build.lib}"/>
<mkdir dir="${sample.projecthosting.build.classes}"/>
<javac srcdir="${sample.projecthosting.src.home}"
destdir="${sample.projecthosting.build.classes}"
debug="${javac.debug}" debuglevel="${javac.debuglevel}"
deprecation="false"
optimize="true">
<classpath refid="sample.projecthosting.compile.classpath"/>
</javac>
<jar jarfile="${sample.projecthosting.read.jar}"
basedir="${sample.projecthosting.build.classes}">
<manifest>
<attribute name="Main-Class" value="${sample.projecthosting.read.main}"/>
</manifest>
</jar>
<jar jarfile="${sample.projecthosting.write.jar}"
basedir="${sample.projecthosting.build.classes}">
<manifest>
<attribute name="Main-Class" value="${sample.projecthosting.write.main}"/>
</manifest>
</jar>
</target>
<!-- samples run -->
<target name="sample.projecthosting.read.run"
depends="sample.projecthosting.build"
description="Runs the projecthosting sample">
<java fork="true" classname="${sample.projecthosting.read.main}">
<arg line="--project ${sample.projecthosting.projectname} --username ${sample.credentials.username} --password ${sample.credentials.password}"/>
<classpath>
<path refid="sample.projecthosting.compile.classpath"/>
<path location="${sample.projecthosting.read.jar}"/>
</classpath>
</java>
</target>
<target name="sample.projecthosting.write.run"
depends="sample.projecthosting.build"
description="Runs the projecthosting sample">
<java fork="true" classname="${sample.projecthosting.write.main}">
<arg line="--project ${sample.projecthosting.projectname} --username ${sample.credentials.username} --password ${sample.credentials.password}"/>
<classpath>
<path refid="sample.projecthosting.compile.classpath"/>
<path location="${sample.projecthosting.write.jar}"/>
</classpath>
</java>
</target>
</project>