Hi everyone,
I'm a relatively new Sphinx user, and this is my first time trying to
get the autodoc extension working. I'm using Sphinx 1.0.3 (stable).
Firstly, here's my project's directory structure:
rdeg...@solitude:~/Documents/Code/django-quotes$ tree -F
.
|-- docs/
| |-- _build/
| |-- conf.py
| |-- index.rst
| |-- make.bat
| |-- Makefile
| |-- models.rst
| |-- quickstart.rst
| |-- _static/
| |-- _templates/
| `-- templatetags.rst
|-- LICENSE
|-- MANIFEST.in
|-- quotes/
| |-- admin.py
| |-- fixtures/
| | `-- test_templatetags.json
| |-- forms.py
| |-- __init__.py
| |-- __init__.pyc
| |-- models.py
| |-- models.pyc
| |-- templates/
| | `-- quotes/
| | `-- quote.html
| |-- templatetags/
| | |-- __init__.py
| | `-- quotes_tags.py
| `-- tests.py
|-- README
`-- setup.py
9 directories, 22 files
The file I'm testing my autodoc code in, is `quickstart.rst` in the
docs/ subdirectory. The specific markup code I'm trying to get working
is:
.. automodule:: quotes
:members:
.. autoclass:: quotes.models.Quote
:members:
My application is a single module `quotes`, and provides a `Quote`
model in `quotes.models` which works fine from the command line (in
the django-quotes directory):
>>> from quotes.models import Quote
>>>
Here's my system path insert from conf.py, which I'm sure is where the
problem lies:
sys.path.insert(0, os.path.abspath('../quotes/'))
That path *seems* to make sense to me, since it would be including my
`quotes` module in the system path, at least I think so.
Anyhow, could anyone point out where I've gone wrong? I've been
experimenting with various paths, and syntaxes, but haven't been able
to make autodoc work.
Furthermore, I should just say (for the record), that autodoc IS
enabled, as this snippet from my conf.py shows:
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.viewcode']
Thanks so much for your assistance.
--
You received this message because you are subscribed to the Google Groups
"sphinx-dev" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sphinx-dev?hl=en.