-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
58 lines (54 loc) · 2.57 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
<?xml version="1.0" encoding="UTF-8"?>
<project name="edeco" description="Sitio Web de EDECO" default="app:config">
<resolvepath propertyName="root.path" file="./" />
<available file="${settings.file}" property="settings.file.exists" value="1" />
<if>
<equals arg1="${settings.file.exists}" arg2="1" />
<then>
<property file="${settings.file}" />
</then>
<else>
<property file="${root.path}/build.properties" />
</else>
</if>
<target name="app:local-properties" if="local.properties.exist" depends="app:local-properties-check" description="Load custom properties if present">
<echo message="Loading custom properties..." />
<property file="${root.path}/local.build.properties" override="true" />
</target>
<target name="app:local-properties-check" description="Checks if there are custom properties to load">
<available file="${root.path}/local.build.properties" property="local.properties.exist" value="1" />
</target>
<target name="app:config" description="Build configuration files" depends="app:local-properties">
<echo msg="Building application.ini file..." />
<copy file="${root.path}/application/build/templates/application.ini"
tofile="${root.path}/application/configs/application.ini"
overwrite="true">
<filterchain>
<replacetokens begintoken="@@" endtoken="@@">
<token key="email.password" value="${email.password}" />
<token key="gmaps.key" value="${gmaps.key}" />
<token key="csrf.salt" value="${csrf.salt}" />
<token key="db.dsn" value="${db.dsn}" />
</replacetokens>
</filterchain>
</copy>
<copy file="${root.path}/application/build/templates/.admin.htaccess"
tofile="${root.path}/admin.edeco.mx/.htaccess"
overwrite="true">
<filterchain>
<replacetokens begintoken="@@" endtoken="@@">
<token key="app.env" value="${app.env}" />
</replacetokens>
</filterchain>
</copy>
<copy file="${root.path}/application/build/templates/.web.htaccess"
tofile="${root.path}/edeco.mx/.htaccess"
overwrite="true">
<filterchain>
<replacetokens begintoken="@@" endtoken="@@">
<token key="app.env" value="${app.env}" />
</replacetokens>
</filterchain>
</copy>
</target>
</project>