Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?xml version="1.0" encoding="utf-8"?>
- <!--
- -->
- <project name="all" default=""
- xmlns:ivy="antlib:org.apache.ivy.ant" xmlns:ivytasks="antlib:de.bayern.ihv.ivytasks">
- <property name="common.dir" value="${basedir}/common" />
- <property name="wkspace.dir" value="${basedir}" />
- <property name="projects.dir" value="${basedir}/projects" />
- <import file="${common.dir}/common.xml"/>
- <target name="build-list" depends="load-ivy">
- <ivy:buildlist reference="build-path" onMissingDescriptor="skip" >
- <fileset dir="${projects.dir}">
- <include name="*/build.xml" />
- <exclude name="framework/build.xml" />
- <exclude name="converter/build.xml" />
- </fileset>
- </ivy:buildlist>
- </target>
- <target name="jboss-start" description="--> Startet den JBoss">
- <subant target="jboss-start" buildpath="${projects.dir}/ihv-deploy" />
- </target>
- <target name="jboss-stop" description="--> Stoppt den JBoss">
- <subant target="jboss-stop" buildpath="${projects.dir}/ihv-deploy" />
- </target>
- <target name="jboss-clean-install" description="--> Loescht den JBoss und installiert ihn neu">
- <subant target="jboss-clean-install" buildpath="${projects.dir}/ihv-deploy" />
- </target>
- <!-- nur Interne Verwendung am Hudson: es wird geprüft, ob das Deployment schon fertig ist -->
- <target name="deploy-check">
- <subant target="deploy-check" buildpath="${projects.dir}/ihv-deploy" />
- </target>
- <target name="init-test-db" >
- <subant target="init-test-db" buildpath="${projects.dir}/ihv-setup" inheritall="false" />
- <!--echo message="Aufruf bitte im Verzeichnis ${projects.dir}/ihv-setup mit ant init-test-db durchfuehren!" /-->
- </target>
- <target name="test" depends="load-ivy" >
- <echo message="Die Shared-Tests werden ausgeführt" />
- <subant target="test" buildpath="${projects.dir}/ihv-shared" />
- <echo message="Die Client-Tests werden ausgeführt" />
- <subant target="test" buildpath="${projects.dir}/ihv-client" />
- <echo message="Die Server-Tests werden ausgeführt" />
- <subant target="test" buildpath="${projects.dir}/ihv-server" />
- <if>
- <equals arg1="${env.development}" arg2="true" />
- <then>
- <exec executable="${wkspace.dir}/show-test-reports.bat" >
- <arg value="/c" />
- <arg value="show-test-reports.bat" />
- <arg value="-p" />
- </exec>
- </then>
- <else>
- <echo message="Datei konnte nicht ausgeführt werden!" />
- </else>
- </if>
- </target>
- <target name="jasper" description="--> Uebersetzt Server und Client Reports 'on-the-fly'">
- <subant target="jasper" buildpath="${projects.dir}/ihv-server"/>
- <subant target="jasper" buildpath="${projects.dir}/ihv-client"/>
- </target>
- <target name="jasper-server" description="--> Uebersetzt Server Reports 'on-the-fly'">
- <subant target="jasper" buildpath="${projects.dir}/ihv-server"/>
- </target>
- <target name="jasper-client" description="--> Uebersetzt Client Reports 'on-the-fly'">
- <subant target="jasper" buildpath="${projects.dir}/ihv-client"/>
- </target>
- <target name="clean-cache" description="--> Loescht den Ivy-Cache">
- <delete dir="${ivy.default.ivy.user.dir}" />
- </target>
- <target name="dist" depends="install" description="--> Uebersetzt, packt und installiert alle Projekte" />
- <target name="report" depends="build-list">
- <subant target="report" buildpathref="build-path" />
- </target>
- <target name="clean-local" depends="build-list">
- <subant target="clean-local" buildpathref="build-path" />
- </target>
- <target name="install" depends="build-list" description="--> Uebersetzt, packt und installiert alle Projekte">
- <subant target="install" buildpathref="build-path" />
- </target>
- <target name="release" depends="build-list"
- description="--> Uebersetzt, packt und veröffentlicht alle Projekte">
- <subant target="release" buildpathref="build-path"/>
- </target>
- <target name="clean" depends="build-list" description="--> Bereinigt alle Projekte">
- <subant target="clean" buildpathref="build-path"/>
- </target>
- <target name="deploy" description="--> Deployed das lokale IHV.EAR im lokalen JBoss">
- <subant target="deploy" buildpath="${projects.dir}/ihv-deploy" />
- </target>
- <target name="create-module" description="--> Legt ein neues Modul an (ant create-module -Dname=ihv-modul)" >
- <fail unless="name" message="Der Name des neuen Moduls muss angegeben werden" />
- <mkdir dir="${projects.dir}/${name}" />
- <copy todir="${projects.dir}/${name}" >
- <fileset dir="${common.dir}/module-template">
- <include name="**/*" />
- </fileset>
- </copy>
- <replace dir="${projects.dir}/${name}" token="${module.name}" value="${name}" />
- <echo message="${line.separator}use.${name}.revision=" append="true" file="${common.dir}/dependency-template.properties" />
- <echo message="${line.separator}use.${name}.revision=" append="true" file="${user.dependency.file}" />
- </target>
- <target name="install-module" depends="load-ivy, common.-setup-environment" description="--> install modules from one to another repository">
- <!--setproxy proxyhost="www-proxy" proxyport="8080" proxyuser="b3fritschep" proxypassword=""/-->
- <ivy:install organisation="${org}" module="${module}" revision="${rev}" from="${from}" to="${to}" transitive="true"/>
- </target>
- <target name="show-schemaupdate" description="--> Vergleicht die aktuelle Datenbank-Struktur mit der aktuellen BIDL-Struktur">
- <subant target="show-schemaupdate" buildpath="${projects.dir}/ihv-bidl" />
- </target>
- <!-- =================================================================================================
- TARGET: rename
- Es wird mit dem Parameter -Dnewname der neue Modulname übergeben und mit -Doldname
- dar alte Modulname erstetzt.
- Aufruf des Targets erfolgt mit ant rename -Dnewname=ihv-new -Doldname=ihv-modul
- ============================================================================================= -->
- <target name="findbugs" description="--> Ueberpruefen des aktuellen Quelltext auf Fehler" >
- <subant target="findbugs" buildpath="${projects.dir}/support"/>
- </target>
- <target name="checkstyle" description="--> Prueft den aktuellen Quelltext mit Checkstyle" >
- <subant target="checkstyle" buildpath="${projects.dir}/support"/>
- </target>
- <target name="javadoc" depends="build-list" description="--> Generieren einer Java-Dokumentation" >
- <subant target="javadoc" buildpath="${projects.dir}/support" />
- </target>
- <target name="build-server-only" depends="load-ivy" description="--> Es wird nur der Server und abhängige Projekte gebaut." >
- <ivy:buildlist reference="build-path" onMissingDescriptor="skip" >
- <fileset dir="${projects.dir}">
- <include name="ihv-shared/build.xml" />
- <include name="ihv-bidl/build.xml" />
- <include name="ihv-server/build.xml" />
- <include name="ihv-ear/build.xml" />
- </fileset>
- </ivy:buildlist>
- <subant target="install" buildpathref="build-path" />
- </target>
- <target name="clean-build-all" description="--> Es werden das lokale Repository, der IVY-Cache und alle Build Ergebnisse geloescht und danach neu aufgebaut (verhaelt sich wie 'ant clean clean-local clean-cache dist').">
- <antcall target="clean"/>
- <antcall target="clean-local"/>
- <antcall target="clean-cache"/>
- <antcall target="dist"/>
- </target>
- <target name="clean-build-run-tests" description="-->Es werden das lokale Repository, der IVY-Cache und alle Build Ergebnisse geloescht, danach alles kompiliert, deployed sowie Shared-, Client- und Servertests ausgefuehrt." >
- <antcall target="jboss-stop" />
- <antcall target="clean-build-all" />
- <antcall target="deploy" />
- <echo message="3 Minuten Pause" />
- <antcall target="jboss-start" />
- <sleep minutes="3"/>
- <echo message="INIT-TEST-DB wird ausgeführt" />
- <antcall target="init-test-db" />
- <echo message="Test werden ausgeführt" />
- <subant target="test" buildpath="${projects.dir}/ihv-shared" />
- <subant target="test" buildpath="${projects.dir}/ihv-client" />
- <echo message="jboss wird heruntergefahren" />
- <antcall target="jboss-stop" />
- <subant target="test" buildpath="${projects.dir}/ihv-server" />
- </target>
- <target name="view-javahelp-administration">
- <subant target="view-javahelp-administration" buildpath="${projects.dir}/ihv-client" />
- </target>
- <target name="view-javahelp-anmeldung">
- <subant target="view-javahelp-anmeldung" buildpath="${projects.dir}/ihv-client" />
- </target>
- <target name="view-javahelp-benutzerverwaltung">
- <subant target="view-javahelp-benutzerverwaltung" buildpath="${projects.dir}/ihv-client" />
- </target>
- <target name="view-javahelp-mbs">
- <subant target="view-javahelp-mbs" buildpath="${projects.dir}/ihv-client" />
- </target>
- <target name="view-javahelp-reste">
- <subant target="view-javahelp-reste" buildpath="${projects.dir}/ihv-client" />
- </target>
- <target name="view-javahelp-ihv">
- <subant target="view-javahelp-ihv" buildpath="${projects.dir}/ihv-client" />
- </target>
- <target name="coverage" description="Führt eine komplette Code-Coverage durch">
- <antcall target="jboss-stop" />
- <antcall target="jboss-clean-install" />
- <antcall target="clean-build-all" />
- <subant target="cobertura-instrument" buildpath="${projects.dir}/support"/>
- <subant buildpath="${projects.dir}/ihv-ear">
- <target name="clean"/>
- <target name="install"/>
- </subant>
- <subant buildpath="${projects.dir}/ihv-deploy">
- <target name="clean"/>
- <target name="deploy"/>
- </subant>
- <antcall target="jboss-start" />
- <sleep minutes="3"/>
- <echo message="INIT-TEST-DB wird ausgeführt" />
- <antcall target="init-test-db" />
- <antcall target="jboss-stop" />
- <sleep minutes="3"/>
- <delete failonerror="false" file="${jboss.dir}/bin/lff/cobertura.ser"/>
- <antcall target="jboss-start" />
- <sleep minutes="3"/>
- <echo message="Test werden ausgeführt" />
- <subant target="test" buildpath="${projects.dir}/ihv-shared" />
- <subant target="test" buildpath="${projects.dir}/ihv-client" />
- <subant target="test" buildpath="${projects.dir}/ihv-server" />
- <echo message="jboss wird heruntergefahren" />
- <antcall target="jboss-stop" />
- <sleep minutes="3"/>
- <subant target="cobertura-merge" buildpath="${projects.dir}/support"/>
- <subant target="cobertura-report" buildpath="${projects.dir}/support"/>
- </target>
- <target name="pmd">
- <subant target="pmd" buildpath="${projects.dir}/support" />
- </target>
- <target name="cpd">
- <subant target="cpd" buildpath="${projects.dir}/support" />
- </target>
- </project>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement