build.xml
author František Kučera <franta-hg@frantovo.cz>
Sun Apr 03 16:34:42 2011 +0200 (2011-04-03)
changeset 6 801a8935caf7
parent 4 1bb39595a51c
child 7 5b46493979c9
permissions -rw-r--r--
Java funkce pro zjištění poslední úpravy souboru, Atom agregace, konfigurační soubor webu.
     1 <project name="xhtml-web" basedir="." default="generuj">
     2 
     3 	<!-- Používané adresáře – např. zde můžete vstup a výstup nasměrovat do jiného verzovaného úložiště -->
     4 	<property name="vstup" value="vstup"/>
     5 	<property name="výstup" value="výstup"/>
     6 	<property name="šablona" value="šablona"/>
     7 	<property name="temp" value="temp"/>
     8 	<property name="funkce" value="${šablona}/funkce/build/classes"/>
     9 	
    10 	<target	name="generuj" description="Vygeneruje kompletní web." depends="kompiluj-funkce,stránky,agregace">
    11 	</target>
    12 	
    13 	<target name="stránky" description="Vygeneruje XHTML webové stránky.">		
    14 		<xslt basedir="${vstup}" destdir="${výstup}" includes="*.xml" extension=".xhtml" style="${šablona}/stránka.xsl">
    15 			<classpath location="/usr/share/java/saxonb-9.0.jar"/>
    16 			<classpath location="${funkce}"/>
    17 			<factory name="net.sf.saxon.TransformerFactoryImpl">
    18 				<attribute name="http://saxon.sf.net/feature/allow-external-functions" value="true"/>				
    19 			</factory>
    20 		</xslt>
    21 	</target>
    22 	
    23 	<target name="agregace" description="Vytvoří agregované výstupy: RSS, Atom, Sitemap.xml">
    24 		<xslt in="${vstup}/web.conf" out="${výstup}/atom.xml" style="${šablona}/atom.xsl">
    25 			<param name="konfigurák" expression="../vstup/web.conf"/>
    26 			<classpath location="/usr/share/java/saxonb-9.0.jar"/>
    27 			<classpath location="${funkce}"/>			
    28 			<factory name="net.sf.saxon.TransformerFactoryImpl">
    29 				<attribute name="http://saxon.sf.net/feature/allow-external-functions" value="true"/>				
    30 			</factory>
    31 		</xslt>	
    32 	</target>
    33 	
    34 	<target name="kompiluj-funkce" description="">		
    35 		<mkdir dir="${funkce}"/>
    36 		<javac
    37 			srcdir="${šablona}/funkce/src"
    38 			destdir="${funkce}"			
    39 			includeAntRuntime="no">
    40 		</javac>
    41 	</target>
    42 	
    43 </project>