You are here: HomeJoomlacom_sphinxdoc : publish your sphinx documentations in Joomla!

com_sphinxdoc : publish your sphinx documentations in Joomla!

com sphinxdoc iconA Joomla composant and plugin to publish your sphinx documentation in Joomla!. Sphinx generated pages wil be shown as they were classic content. This composant works for me ;) but not sure it will worked for you as it should.

I don't have time to develop it further more, so if you're interested in, contact me on the official repository.

 

The documentation directory.

Under your joomla root folder, create a directory named _sphinxdocs. It will be your root sphinxdocs directory.

mkdir _sphinxdocs

Now create a directory to store your documentation for a package, python-openzwave for example :

mkdir python-openzwave

Update your docs

You need to update your docs to add a new target in Makefile. You also need to install the joomla theme. Look at the sphinx directory in the sources.

cp Makefile pathtoyourdoc/
cp -Rf _themes/joomla pathtoyourthemes/

You may also need to add an _index page. Here is my _index_api.rst :

* :doc:`Network </network>`
* :doc:`Controller </controller>`
* :doc:`Nodes </node>`
* :doc:`Commands </command>`
* :doc:`Groups and associations </group>`
* :doc:`Scenes </scene>`
* :doc:`Values </value>`
* :doc:`Options for manager </option>`
* :doc:`Objects and Exceptions </object>`
* :doc:`Enums and data types </data>`

You can now generate your doc for joomla :

make joomla

And copy them to your sphinxdoc home directory :

cp -Rf _build/joomla/* pathtojooml/_sphinxdocs/python-openzwave/

Install the Joomla! composant and plugin

First, generate the composant and the plugin (and activate it)  :

./createpackages.sh

And install them in Joomla!

After that, you need to create a category in com_sphinxdoc.

Now create a new documentation. Important fields are directory and index.

directory : the directory created before : python-openzwave
index : the index previously created : _index_api.html

Remenber the id of the documentation, you need it after when calling the plugin.

Now, you can create an article, and put a call to the plugin inside it :

{sphinxdoc documentation id}

Remove the space between sphinxdoc and documentation.

Save the article and that's all.

Look at this example.

Add comment


Security code
Refresh

Free business joomla templates