Hello Jirka, thanks, makes sense your setup.
Best regards, Lars 2011/11/1 Jirka Kosek <ji...@kosek.cz> > On 29.10.2011 11:59, Lars Vogel wrote: > > > thanks. This also looks like a great solution. I think the suggestion > from > > Robert is easier for my toolchain as I only have to change the > customization > > layer and not have an additional step. But your suggestion is great as it > > shows options how to further influence the result. > > > > How to you separate the step XHTML and EPUB creation? I believe the epub > > XSLT stylesheets do this in one step? > > I use Ant to manage build process. I have separate target for Kindle > which applies this fixing transformation on output of DocBook > stylesheets before ziping final epub file. Something like: > > <target name="kindle"> > ... call normal DocBook epub stylesheet .. > > <!-- Make fixes for Kindle in generated XHTML --> > <xslt style="kindleize.xsl" force="true" basedir="${out.dir}" > includes="*.xhtml" destdir="${out.dir}/kindle"> > <factory name="net.sf.saxon.TransformerFactoryImpl"/> > <classpath location="${saxon9.jar}"/> > </xslt> > > <!-- Replace original XHTML files with "kindleized" ones --> > <copy todir="${out.dir}"> > <fileset dir="${out.dir}/kindle"/> > <globmapper from="*.html" to="*.xhtml"/> > </copy> > > <!-- Delete temporary "kindleized" files --> > <delete dir="${out.dir}/kindle"/> > > <!-- Build final epub package --> > <zip destfile="${out}-kindle.epub" > basedir="ebook" > includes="mimetype" > compress="false" > /> > <zip destfile="${out}-kindle.epub" > basedir="ebook" > excludes="mimetype" > update="true" > compress="true" > keepcompression="true" > /> > > </target> > > > -- > ------------------------------------------------------------------ > Jirka Kosek e-mail: ji...@kosek.cz http://www.kosek.cz > ------------------------------------------------------------------ > Profesionální školení a poradenství v oblasti technologií XML. > Podrobný přehled školení http://xmlguru.cz/skoleni/ > ------------------------------------------------------------------ > http://docbook.cz Stránky o dokumentačním formátu DocBook > http://xmlguru.cz Blog mostly about XML for English readers > ------------------------------------------------------------------ > > -- Lars http://www.vogella.de - Eclipse, Android and Java Tutorials http://www.twitter.com/vogella - Lars on Twitter