forked from 3pillarlabs/socialauth
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
281 lines (253 loc) · 9.05 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
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
<?xml version="1.0" ?>
<project name="socialauthSDK" default="init">
<property name="basedir" value="." />
<property file="${basedir}/env.properties" />
<property name="sdk.name" value="socialauth-java-sdk-${sdk.version}" />
<property name="distDir" value="${basedir}/${sdk.name}" />
<property name="javadoc" value="${distDir}/javadoc" />
<property name="examples" value="${distDir}/examples" />
<property name="dist" value="${distDir}/dist" />
<property name="src" value="${distDir}/src" />
<property name="dependencies" value="${distDir}/dependencies" />
<property name="project.socialauth" value="socialauth" />
<property name="project.filter" value="socialauth-filter" />
<property name="project.spring" value="socialauth-spring" />
<property name="project.seam" value="socialauth-seam" />
<property name="project.cdi" value="socialauth-cdi" />
<property name="project.cmd.utility" value="socialauth-cmd-utility" />
<property name="project.struts.demo" value="socialauth-struts-demo" />
<property name="project.struts.filter.demo" value="socialauth-struts-filter-demo" />
<property name="project.grails.demo" value="socialauth-grails-demo" />
<property name="project.seam.demo" value="socialauth-seam-demo" />
<property name="project.cdi.demo" value="socialauth-cdi-demo" />
<property name="project.socialauth.demo" value="socialauthdemo" />
<path id="libraries">
<fileset dir="${tomcat.home}/lib">
<include name="**/*.jar" />
</fileset>
</path>
<target name="clean">
<delete dir="${distDir}" failonerror="true" />
<delete file="${basedir}/{sdk.name}" />
<delete file="${basedir}/{sdk.name}.zip" />
<delete>
<fileset dir="." includes="socialauth*.jar" />
</delete>
<delete>
<fileset
dir="${projects.path}/${project.seam.demo}/WebContent/WEB-INF/lib"
includes="socialauth*.jar" />
</delete>
<delete>
<fileset dir="${projects.path}/${project.grails.demo}/socialauthdemo/lib"
includes="socialauth*.jar" />
</delete>
</target>
<target name="init"
depends="clean,socialauthJar,copyJavadocs,copyExamples,copyDependencies,copySrc,copyPropertiesFile,copyReadMe,createZip" />
<target name="socialauthJar">
<echo message="Copying main jar in dist directory" />
<copy todir="${dist}">
<fileset dir="${projects.path}/${project.socialauth}/target">
<filename name="/socialauth-${socialauth.core.version}.jar" />
</fileset>
</copy>
<copy todir="${projects.path}/${project.seam.demo}/WebContent/WEB-INF/lib">
<fileset dir=".">
<filename name="/socialauth-${socialauth.core.version}.jar" />
</fileset>
</copy>
<copy todir="${projects.path}/${project.grails.demo}/socialauthdemo/lib">
<fileset dir=".">
<filename name="/socialauth-${socialauth.core.version}.jar" />
</fileset>
</copy>
<copy todir="${dist}">
<fileset dir="${projects.path}/${project.filter}/target">
<filename name="/${project.filter}-${socialauth.filter.version}.jar" />
</fileset>
</copy>
<copy todir="${projects.path}/${project.grails.demo}/socialauthdemo/lib">
<fileset dir=".">
<filename name="${project.filter}-${socialauth.filter.version}.jar" />
</fileset>
</copy>
<copy todir="${dist}">
<fileset dir="${projects.path}/${project.spring}/target">
<filename name="/${project.spring}-${socialauth.spring.version}.jar" />
</fileset>
</copy>
<copy todir="${dist}">
<fileset dir="${projects.path}/${project.seam}/target">
<filename name="/${project.seam}-${socialauth.seam.version}.jar" />
</fileset>
</copy>
<copy todir="${projects.path}/${project.seam.demo}/WebContent/WEB-INF/lib">
<fileset dir=".">
<filename name="${project.seam}-${socialauth.seam.version}.jar" />
</fileset>
</copy>
<copy todir="${dist}">
<fileset dir="${projects.path}/${project.cdi}/target">
<filename name="/${project.cdi}-${socialauth.cdi.version}.jar" />
</fileset>
</copy>
<copy todir="${dist}">
<fileset dir="${projects.path}/${project.cmd.utility}/target">
<filename
name="/${project.cmd.utility}-${socialauth.cmd.utility.version}.jar" />
</fileset>
</copy>
</target>
<target name="copyDependencies">
<echo message="Copying jar in dependencies directory" />
<copy todir="${dependencies}">
<fileset dir="./libs" />
</copy>
</target>
<target name="copySrc">
<echo message="Copying source in src directory" />
<copy todir="${src}/${project.socialauth}">
<fileset dir="${projects.path}/${project.socialauth}">
<exclude name="**/.svn" />
</fileset>
</copy>
<copy todir="${src}/${project.filter}">
<fileset dir="${projects.path}/${project.filter}">
<exclude name="**/.svn" />
</fileset>
</copy>
<copy todir="${src}/${project.spring}">
<fileset dir="${projects.path}/${project.spring}">
<exclude name="**/.svn" />
</fileset>
</copy>
<copy todir="${src}/${project.seam}">
<fileset dir="${projects.path}/${project.seam}">
<exclude name="**/.svn" />
</fileset>
</copy>
<copy todir="${src}/${project.cdi}">
<fileset dir="${projects.path}/${project.cdi}">
<exclude name="**/.svn" />
</fileset>
</copy>
<copy todir="${src}/${project.cmd.utility}">
<fileset dir="${projects.path}/${project.cmd.utility}">
<exclude name="**/.svn" />
</fileset>
</copy>
</target>
<target name="copyExamples">
<echo message="Copying example projects in example directory" />
<copy todir="${examples}/${project.struts.demo}">
<fileset dir="${projects.path}/${project.struts.demo}">
<exclude name="**/.svn" />
</fileset>
</copy>
<copy todir="${examples}/${project.struts.filter.demo}">
<fileset dir="${projects.path}/${project.struts.filter.demo}">
<exclude name="**/.svn" />
</fileset>
</copy>
<copy todir="${examples}/${project.seam.demo}">
<fileset dir="${projects.path}/${project.seam.demo}">
<exclude name="**/.svn" />
</fileset>
</copy>
<copy todir="${examples}/${project.cdi.demo}">
<fileset dir="${projects.path}/${project.cdi.demo}">
<exclude name="**/.svn" />
</fileset>
</copy>
<copy todir="${examples}/${project.grails.demo}">
<fileset dir="${projects.path}/${project.grails.demo}">
<exclude name="**/.svn" />
</fileset>
</copy>
<copy todir="${examples}/${project.socialauth.demo}">
<fileset dir="${projects.path}/${project.socialauth.demo}">
<exclude name="**/.svn" />
</fileset>
</copy>
</target>
<target name="copyPropertiesFile">
<echo message="Copying Properties file" />
<copy todir="${dist}">
<fileset
dir="${projects.path}/${project.struts.filter.demo}/src/main/java">
<filename name="/oauth_consumer.properties" />
</fileset>
</copy>
<copy todir="${dist}">
<fileset
dir="${projects.path}/${project.struts.filter.demo}/src/main/java">
<filename name="/socialauth_filter.properties" />
</fileset>
</copy>
</target>
<target name="copyReadMe">
<echo message="Copying ReadMe file" />
<copy todir="${distDir}">
<fileset dir=".">
<filename name="/ReadMe.txt" />
</fileset>
</copy>
</target>
<target name="copyJavadocs">
<echo message="Copying Javadocs" />
<copy todir="${javadoc}/${project.socialauth}">
<fileset dir="${projects.path}/${project.socialauth}/target/site/apidocs" />
</copy>
<copy todir="${javadoc}/${project.filter}">
<fileset dir="${projects.path}/${project.filter}/target/site/apidocs" />
</copy>
<copy todir="${javadoc}/${project.spring}">
<fileset dir="${projects.path}/${project.spring}/target/site/apidocs" />
</copy>
<copy todir="${javadoc}/${project.seam}">
<fileset dir="${projects.path}/${project.seam}/target/site/apidocs" />
</copy>
<copy todir="${javadoc}/${project.cdi}">
<fileset dir="${projects.path}/${project.cdi}/target/site/apidocs" />
</copy>
<copy todir="${javadoc}/${project.cmd.utility}">
<fileset
dir="${projects.path}/${project.cmd.utility}/target/site/apidocs" />
</copy>
</target>
<target name="createZip">
<zip destfile="./${sdk.name}.zip">
<fileset dir="${distDir}" />
</zip>
</target>
<target name="doc" depends="filterDoc">
<javadoc destdir="${javadoc}/${project.socialauth}"
sourcepath="${projects.path}/${project.socialauth}/src/main/java"
packagenames="*" windowtitle="SocialAuth" classpathref="libraries" />
</target>
<target name="filterDoc" depends="springDoc">
<javadoc destdir="${javadoc}/${project.filter}"
sourcepath="${projects.path}/${project.filter}/src/main/java"
packagenames="*" windowtitle="SocialAuth Filter">
</javadoc>
</target>
<target name="springDoc" depends="seamDoc">
<javadoc destdir="${javadoc}/${project.spring}"
sourcepath="${projects.path}/${project.spring}/src/main/java"
packagenames="*" windowtitle="SocialAuth Spring">
</javadoc>
</target>
<target name="seamDoc" depends="cdiDoc">
<javadoc destdir="${javadoc}/${project.seam}"
sourcepath="${projects.path}/${project.seam}/src/main/java"
packagenames="*" windowtitle="SocialAuth Seam">
</javadoc>
</target>
<target name="cdiDoc">
<javadoc destdir="${javadoc}/${project.cdi}"
sourcepath="${projects.path}/${project.cdi}/src/main/java"
packagenames="*" windowtitle="SocialAuth CDI">
</javadoc>
</target>
</project>