[daisy] Automatic HTMLHelp Publishing

Robert Kindl rob at exec.cz
Tue Apr 10 04:44:16 CDT 2007


I'm currently solving following problem:
a) I want to create/write content in daisy and prepare book
b) compile book to HTMLHelp (in adition to producting HTML and PDF)
c) On daily schedule (or any time during build-time of other things in our
integration process) produce book with all this outputs.
d) Automatically bundle result in our installation scripts

Now my comments:
ad b) I already realized custom book PublicationType which is able to
produce .hhp .hhc and .hhk files
But I'm missing posibility to compile and release .chm during this process:

Suggested solution b1:
    <custom class="ExecuteCommandTask"
            program="C:\Program Files\HTML Help Workshop\hhc.exe"
            commandline="output\book.hhp"
            workingdir="output"
            errorlevel="1" <!--HHC returns errorlevel=1 on success -->
            />
    <custom class="ExecuteCommandTask"
            program="copy"
            commandline="/b book.chm D:\LatestBook"
            workingdir="output"
            errorlevel="0"
            />

Suggested solution b2:
   <zip>
    <custom class="ExecuteCommandTask"
            program="copy"
            commandline="/b *.zip D:\LatestBook"
            workingdir="output"
            errorlevel="0"
            />

Suggested solution b3:
   <zip>
    <copyResource from="currentpublicationdir:/output/*.zip"
to="D:\LatestBook" />

In solutions b2 and b3 I will run HTMLHelp compiler as part of my
integration process - it's not problem.

Can anyone help me with writing this custom ExecuteCommandTask?
I'm not able to do this personally as I'm not Java programmer.
I will share my .xsl for HTMLHelp publication in exchange ;-)

ad c) There should be some posibility (API) to trigger book publication
externally.

Suggested solution:

Currently book publication start with following URL:
http://server:8888/books/createBookInstance?bookDefinitionDocumentId=112-EX&bookDefinitionBranchId=1&bookDefinitionLanguageId=2

I suggest adding one parameter useDefaultSettings=true
http://server:8888/books/createBookInstance?bookDefinitionDocumentId=112-EX&bookDefinitionBranchId=1&bookDefinitionLanguageId=2&useDefaultSettings=true
which will simply start publication right now (without asking for any
parameters)

Now it would be simple to use WGET.exe to trigger book publication at any
time

Thanks for any help

Rob




More information about the daisy mailing list