forrest-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sean Wheller <s...@inwords.co.za>
Subject Re: map:transform to docbook xsl
Date Sun, 03 Oct 2004 09:06:24 GMT
On Sunday 03 October 2004 03:31, David Crossley wrote:
> > Patience with me. I am trying to get forrest to use the nwalsh docbook
> > stylesheets directly as per
> > http://localhost:8888/faq.html#docbook
>
> And then following the general notes for adding
> project sitemaps in the "Using Forrest" document
> and the "Project Sitemaps" document.
>
> I presume that you are using the Forrest-0.6-dev
> SVN trunk.

Yes. I have followed these instructions over and over and yes I  use SVN 
trunk.

Just to make sure. I ripped forrest out, then:
1. did svn checkout of trunk

2. ./build.sh (succeed) env was already set.

3. create new dir and forrest seed (works)

4. execute forrest run from root of new seed project to text if I can see the 
proj, I can. Stop Jetty.

5. Add to site.xml

<about label="Documents">
        <index label="XML Solves Problems" href="db-article.html" 
description="XML Solves Tech Publishing Problems"/>
    </about>

7. cp db-article.xml to seed project xdocs/

8. forrest run. I see changes to menu.

9. Click "XML Solves Problems" db-article.xml is transformed to document 
(default docbooktodocument.xsl). Stop jetty.

10. Write new sitemap.xmap saved to documentation/sitemap.xmap 
<?xml version="1.0" encoding="UTF-8"?>
<map:sitemap xmlns:map="http://apache.org/cocoon/sitemap/1.0">
    <map:pipelines>
        <map:pipeline>
            <map:match pattern="db-**.xml">
                <map:generate src="{project:content.xdocs}db-{1}.xml"/>
                <map:transform
                src="/usr/share/xml/docbook/stylesheet/nwalsh/1.64.1/xhtml/docbook.xsl"/>
                <map:serialize/>
            </map:match>
        </map:pipeline>
    </map:pipelines>
</map:sitemap>

No need to register the docbook dtd since forrest ships with it and it is 
already configured in forrest.xmap.
<sourcetype name="docbook-v4.2">
          <document-declaration public-id="-//OASIS//DTD DocBook XML 
V4.2//EN" />
        </sourcetype>

I understand the the sitemap.xmap in see documentation/ will take precedence 
over forrest.xmap
<map:when test="docbook-v4.2">
            <map:transform src="{forrest:stylesheets}/docbook2document.xsl" />
          </map:when>

11. Forrest run and try to see the db-article. NO LUCK:-( Just a blank body. 
As explained in previous message.

Thanks for your help. If you have any other questions, let me know.
I am considering using Forrest for a new Open Source project and really want 
it to work as all sources are in docbook xml. I get this right, I will update 
the forrest docs and send a patch.

Attached is the db-article.xml for you to test.

-- 
Sean Wheller
Technical Author
084-8549408
sean@inwords.co.za
http://www.inwords.co.za

Mime
View raw message