1. Yusuke MURAOKA
  2. sphinx document transformer

Overview

A sphinx document tranformer

Introduction

This is a sphinx document transformer with xdv and an open source design.

Assumption

  • You are familiar with zc.buildout.
  • You are familiar with xml and perhaps xslt.

Requirement

  • libxml2 and libxslt to use lxml.

HowTo

  1. Setup your buildout.

  2. Run install command with document_root variable.:

    ./bin/buildout buildout:document_root=target_sphinx_html_directory install
    

    The variable must be the path to root of sphinx output html directory. This transformer assumes the sphinx document is generated with basic theme.

    Then some buildout dependant files must exist at the local buildout directory.

  3. Check layout with Paste.:

    ./bin/paster serve wsgi.ini
    

    Then open the url http://localhost:8000/ with your browser.

  4. If everything looks like OK, make static output.:

    ./bin/python convert.py
    

    Few seconds later, the generated files must be in output directory if no error happened.

Others

  • If you are new for xdv, static/rule.xml might be good knowledge.
  • The template way now I taken is horrible. Should be smart. :^)

Contact

MURAOKA Yusuke <yusuke@jbking.org>

Feel free to mail me any question or comment.