source: src/webapp/build.xml@ 74c3571

debian/bullseye
Last change on this file since 74c3571 was 883b4a5, checked in by Joachim Langenbach <joachim.langenbach@…>, 8 years ago

Added GNUBoat tiles to leaflet map

  • Property mode set to 100644
File size: 5.1 KB
RevLine 
[e82ce68]1<?xml version="1.0" encoding="UTF-8"?>
[883b4a5]2<!--
3 Copyright (C) 2017 - 2019 EngSaS - Engineering Solutions and Services Langenbach. All rights reserved.
4
5 This program is free software: you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation, either version 3 of the License, or
8 (at your option) any later version.
9
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with this program. If not, see <http://www.gnu.org/licenses/>.
17-->
[e82ce68]18<project name="GNUBoatWebApp" default="dist">
19
[e62038b]20 <property name="builddir" value="../../build/webapp" override="true" />
[e82ce68]21
[46eee06]22 <fileset dir="./common/resources/" id="filesCommonResources">
23 </fileset>
24 <fileset dir="./common/css/" id="filesCommonCss">
25 </fileset>
[3b7e9f6]26 <fileset dir="./common/js/" id="filesCommonJs">
27 </fileset>
[46eee06]28 <fileset dir="../icon/" id="filesGnuboatIcons">
29 <include name="gnuboat-256-256-transparent.png"/>
30 </fileset>
31
[e82ce68]32 <target name="prepare">
33 <echo msg="Making directory ${builddir}" />
34 <mkdir dir="${builddir}"/>
35 </target>
[6f38643]36 <target name="buildwebclient" depends="prepare">
[e82ce68]37 <echo msg="Copying files to build directory"/>
[24d4504]38 <fileset dir="./webclient" id="filesWebclient">
[e82ce68]39 <!-- <exclude name=""/> -->
40 </fileset>
41
[6f38643]42 <copy todir="${builddir}/webclient">
[24d4504]43 <fileset refid="filesWebclient"/>
[e82ce68]44 </copy>
[6f38643]45 <copy todir="${builddir}/webclient/resources">
[5149714]46 <fileset refid="filesGnuboatIcons"/>
[46eee06]47 <fileset refid="filesCommonResources"/>
48 </copy>
49 <copy todir="${builddir}/webclient/css">
50 <fileset refid="filesCommonCss"/>
51 </copy>
[3b7e9f6]52 <copy todir="${builddir}/webclient/js">
53 <fileset refid="filesCommonJs"/>
54 </copy>
[6f38643]55 </target>
56 <target name="buildwebservice" depends="prepare">
[89c32b1]57 <fileset dir="./webservice" id="filesWebservice">
[f03591a]58 <exclude name="mbtiles/**"/>
[c455d7b]59 <exclude name="tests/**"/>
[a50c18f]60 <exclude name="config/**"/>
[89c32b1]61 </fileset>
[6f38643]62 <fileset dir="./webservice/mbtiles" id="filesWebserviceMaps">
63 <!-- <exclude name=""/> -->
64 </fileset>
65
66 <copy todir="${builddir}/webservice">
67 <fileset refid="filesWebservice"/>
68 </copy>
[f03591a]69 <copy todir="${builddir}/webservice/maps">
[6f38643]70 <fileset refid="filesWebserviceMaps"/>
71 </copy>
[e82ce68]72 </target>
[883b4a5]73 <target name="buildwebserver" depends="prepare">
[2fa2ef8]74 <echo msg="Copying files to build directory"/>
75 <fileset dir="./webserver" id="filesWebserver">
76 <!-- <exclude name=""/> -->
77 </fileset>
78
79 <copy todir="${builddir}/webserver">
80 <fileset refid="filesWebserver"/>
81 </copy>
82 <copy todir="${builddir}/webserver/resources">
83 <fileset refid="filesGnuboatIcons"/>
84 <fileset refid="filesCommonResources"/>
85 </copy>
86 <copy todir="${builddir}/webserver/css">
87 <fileset refid="filesCommonCss"/>
88 </copy>
89 <copy todir="${builddir}/webserver/js">
90 <fileset refid="filesCommonJs"/>
91 </copy>
[883b4a5]92 <mkdir dir="${builddir}/webserver/tiles"/>
[2fa2ef8]93 </target>
[e82ce68]94
95 <fileset dir="${builddir}" id="filesWebApp"/>
96
97
[2fa2ef8]98 <target name="dist" depends="buildwebservice,buildwebclient,buildwebserver,test">
[e82ce68]99 <echo msg="Creating archive"/>
[008bce9]100 <tar destfile="${builddir}/..//gnuboat-webapp.tar.gz" compression="gzip">
[e82ce68]101 <fileset refid="filesWebApp"/>
[008bce9]102 </tar>
[c455d7b]103 <echo msg="Files copied and compressed in build directory weblcient.tar.gz OK!" />
[e82ce68]104 </target>
[008bce9]105
[2fa2ef8]106 <target name="testdist" depends="buildwebservice,buildwebclient,buildwebserver,test">
[e82ce68]107 <echo msg="Install project into ${user.home}/public_html/gnuboat"/>
[a50c18f]108 <fileset id="filesConfig" dir="./webservice/config">
[008bce9]109 <include name="config.php"/>
110 </fileset>
[a50c18f]111 <fileset id="filesLogs" dir="./webservice/tests/logs">
[008bce9]112 <include name="*.log"/>
113 </fileset>
114
[e82ce68]115 <copy todir="${user.home}/public_html/gnuboat">
116 <fileset refid="filesWebApp"/>
117 </copy>
[a50c18f]118 <copy todir="${user.home}/public_html/gnuboat/webservice/tests/logs">
[008bce9]119 <fileset refid="filesLogs"/>
120 </copy>
121 <copy todir="${user.home}/public_html/gnuboat/webservice/config">
122 <fileset refid="filesConfig"/>
123 </copy>
[e82ce68]124 </target>
[3c9166b]125
[86442cb]126 <target name="test">
[c0e66e6]127 <exec command="php phpunit-7.4.3.phar" passthru="true" checkreturn="true"/>
[0662b2d]128 <!--<phpunit pharlocation="phpunit-4.8.9.phar" configuration="phpunit.xml" haltonfailure="true" haltonerror="true" printsummary="true" codecoverage="false">
129 <formatter type="plain" usefile="false"/> -->
[008bce9]130 <!--<formatter type="JUnit" usefile="true"/>-->
[0662b2d]131<!-- <batchtest>
[86442cb]132 <fileset dir="webservice">
133 <include name="tests/*Test.php"/>
134 </fileset>
135 </batchtest>
[0662b2d]136 </phpunit>-->
[86442cb]137 </target>
[3c9166b]138
[573626d]139 <target name="testdist-sample-logs" depends="testdist">
[3c9166b]140 <echo msg="Install sample logs"/>
[573626d]141 <fileset id="filesSampleLogs" dir="../../sample-logs">
[3c9166b]142 <include name="*.log"/>
143 </fileset>
[573626d]144 <fileset id="filesCalcLogs" dir="../../sample-logs/calc-demo">
[3c9166b]145 <include name="*.log"/>
146 </fileset>
147 <copy todir="${user.home}/public_html/gnuboat/webservice/tests/logs">
148 <fileset refid="filesSampleLogs"/>
149 <fileset refid="filesCalcLogs"/>
150 </copy>
151 </target>
[e82ce68]152</project>
Note: See TracBrowser for help on using the repository browser.