source: src/webapp/build.xml@ 3b7e9f6

debian/bullseye
Last change on this file since 3b7e9f6 was 3b7e9f6, checked in by Joachim Langenbach <joachim.langenbach@…>, 8 years ago
  • Removed not needed styles from GnuBoatColors.css
  • Added subnamespace GnuBoat.Webclient in javascripts
  • Moved common methods into GnuBoat.js (like displayMessage())
  • side-menu.css: Menu is hidden by default (independend from display resolution
  • Property mode set to 100644
File size: 3.6 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<project name="GNUBoatWebApp" default="dist">
3
4 <property name="builddir" value="../../build/webapp" override="true" />
5
6 <fileset dir="./common/resources/" id="filesCommonResources">
7 </fileset>
8 <fileset dir="./common/css/" id="filesCommonCss">
9 </fileset>
10 <fileset dir="./common/js/" id="filesCommonJs">
11 </fileset>
12 <fileset dir="../icon/" id="filesGnuboatIcons">
13 <include name="gnuboat-256-256-transparent.png"/>
14 </fileset>
15
16 <target name="prepare">
17 <echo msg="Making directory ${builddir}" />
18 <mkdir dir="${builddir}"/>
19 </target>
20 <target name="buildwebclient" depends="prepare">
21 <echo msg="Copying files to build directory"/>
22 <fileset dir="./webclient" id="filesWebclient">
23 <!-- <exclude name=""/> -->
24 </fileset>
25
26 <copy todir="${builddir}/webclient">
27 <fileset refid="filesWebclient"/>
28 </copy>
29 <copy todir="${builddir}/webclient/resources">
30 <fileset refid="filesGnuboatIcons"/>
31 <fileset refid="filesCommonResources"/>
32 </copy>
33 <copy todir="${builddir}/webclient/css">
34 <fileset refid="filesCommonCss"/>
35 </copy>
36 <copy todir="${builddir}/webclient/js">
37 <fileset refid="filesCommonJs"/>
38 </copy>
39 </target>
40 <target name="buildwebservice" depends="prepare">
41 <fileset dir="./webservice" id="filesWebservice">
42 <exclude name="mbtiles/**"/>
43 <exclude name="tests/**"/>
44 <exclude name="config/**"/>
45 </fileset>
46 <fileset dir="./webservice/mbtiles" id="filesWebserviceMaps">
47 <!-- <exclude name=""/> -->
48 </fileset>
49
50 <copy todir="${builddir}/webservice">
51 <fileset refid="filesWebservice"/>
52 </copy>
53 <copy todir="${builddir}/webservice/maps">
54 <fileset refid="filesWebserviceMaps"/>
55 </copy>
56 </target>
57
58 <fileset dir="${builddir}" id="filesWebApp"/>
59
60
61 <target name="dist" depends="buildwebservice,buildwebclient,test">
62 <echo msg="Creating archive"/>
63 <tar destfile="${builddir}/..//gnuboat-webapp.tar.gz" compression="gzip">
64 <fileset refid="filesWebApp"/>
65 </tar>
66 <echo msg="Files copied and compressed in build directory weblcient.tar.gz OK!" />
67 </target>
68
69 <target name="testdist" depends="buildwebservice,buildwebclient,test">
70 <echo msg="Install project into ${user.home}/public_html/gnuboat"/>
71 <fileset id="filesConfig" dir="./webservice/config">
72 <include name="config.php"/>
73 </fileset>
74 <fileset id="filesLogs" dir="./webservice/tests/logs">
75 <include name="*.log"/>
76 </fileset>
77
78 <copy todir="${user.home}/public_html/gnuboat">
79 <fileset refid="filesWebApp"/>
80 </copy>
81 <copy todir="${user.home}/public_html/gnuboat/webservice/tests/logs">
82 <fileset refid="filesLogs"/>
83 </copy>
84 <copy todir="${user.home}/public_html/gnuboat/webservice/config">
85 <fileset refid="filesConfig"/>
86 </copy>
87 </target>
88
89 <target name="test">
90 <exec command="php phpunit-7.4.3.phar" passthru="true" checkreturn="true"/>
91 <!--<phpunit pharlocation="phpunit-4.8.9.phar" configuration="phpunit.xml" haltonfailure="true" haltonerror="true" printsummary="true" codecoverage="false">
92 <formatter type="plain" usefile="false"/> -->
93 <!--<formatter type="JUnit" usefile="true"/>-->
94<!-- <batchtest>
95 <fileset dir="webservice">
96 <include name="tests/*Test.php"/>
97 </fileset>
98 </batchtest>
99 </phpunit>-->
100 </target>
101
102 <target name="testdist-sample-logs" depends="testdist">
103 <echo msg="Install sample logs"/>
104 <fileset id="filesSampleLogs" dir="../../sample-logs">
105 <include name="*.log"/>
106 </fileset>
107 <fileset id="filesCalcLogs" dir="../../sample-logs/calc-demo">
108 <include name="*.log"/>
109 </fileset>
110 <copy todir="${user.home}/public_html/gnuboat/webservice/tests/logs">
111 <fileset refid="filesSampleLogs"/>
112 <fileset refid="filesCalcLogs"/>
113 </copy>
114 </target>
115</project>
Note: See TracBrowser for help on using the repository browser.