~imc-pl/imc-pl/trunk

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
<?xml version="1.0" ?>
<project name="IGC" basedir="." default="install-igc">
  <property file="build.conf"/>
  <target name="install-igc">
  </target>
  <target name="prepare-settings">
  	<copy file="${basedir}/app/sites/default/igc-template.settings.php" tofile="${basedir}/app/sites/default/settings.php" overwrite="true" />
  	<reflexive file="${basedir}/app/sites/default/settings.php">
	  	<filterchain>
	  	  <replaceregexp>
	  		<regexp pattern="username" replace="${mysql.user}" />
	  		<regexp pattern="password" replace="${mysql.pass}"/>
	  		<regexp pattern="@localhost" replace="@${mysql.host}" />
	  		<regexp pattern="databasename" replace="${mysql.db}"/>	  	  	
	  	  </replaceregexp>
	  	</filterchain>  		
  	</reflexive>
  </target>
  <target name="install_bootstrap_db">
  	<exec command="mysql -u${mysql.user} -P${mysql.port} -p${mysql.pass} -h${mysql.host} -e 'DROP DATABASE ${mysql.db}'" />
  	<exec command="mysql -u${mysql.user} -P${mysql.port} -p${mysql.pass} -h${mysql.host} -e 'CREATE DATABASE ${mysql.db}'" />
  	<exec command="mysql -u${mysql.user} -P${mysql.port} -p${mysql.pass} -h${mysql.host} ${mysql.db} &lt; ${basedir}/mr/build/db_bootstrap.sql" />
  </target>
  <!-- PHP copy/paste analysis -->
    <target name="phpcpd">
        <echo msg="PHP Copy/Paste..." />
        <exec command="phpcpd --log-pmd=mr/build/results/pcpd.xml app/sites/all" escape="false" />
    </target>
  <target name="pdepend">
      <echo msg="PHP Depend..." />
      <exec command="pdepend --jdepend-xml=mr/build/results/pdepend.xm  app/sites/all" escape="false" />
  </target>

	
  <target name="install_igc">
  	<exec command="${drush} -l ${main_url} -y -r ${basedir}/app enable igc_project" />
  </target>
  <target name="install_fixtures"> 
  </target>
</project>