summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulien Jehannet <julien.jehannet@logilab.fr>2010-03-24 18:43:25 +0100
committerJulien Jehannet <julien.jehannet@logilab.fr>2010-03-24 18:43:25 +0100
commit9d586d64ee08c64eae07d1d5527ae0c25de888eb (patch)
tree8af58f43254bdcaeb8cb5fee52cf23116b2a0259
parentd357ea88211fc3abdfdddcda1a97a625325cc804 (diff)
downloadlogilab-common-9d586d64ee08c64eae07d1d5527ae0c25de888eb.tar.gz
[D] doc: fix some restructured blocks
-rw-r--r--dbf.py20
-rw-r--r--sphinxutils.py12
2 files changed, 17 insertions, 15 deletions
diff --git a/dbf.py b/dbf.py
index b6cdd4e..9ca1252 100644
--- a/dbf.py
+++ b/dbf.py
@@ -1,14 +1,15 @@
# -*- coding: utf-8 -*-
-"""
-This is a DBF reader which reads Visual Fox Pro DBF format with Memo field.
+"""This is a DBF reader which reads Visual Fox Pro DBF format with Memo field
Usage:
- rec = readDbf('test.dbf')
- for line in rec:
- print line['name']
-@author Yusdi Santoso
-@date 13/07/2007
+>>> rec = readDbf('test.dbf')
+>>> for line in rec:
+>>> print line['name']
+
+:author: Yusdi Santoso
+:date: 13/07/2007
+
http://www.physics.ox.ac.uk/users/santoso/Software.Repository.html
page says code is "available as is without any warranty or support".
"""
@@ -191,8 +192,9 @@ def readDbf(filename):
"""
Read the DBF file specified by the filename and
return the records as a list of dictionary.
- @param filename File name of the DBF
- @return List of rows
+
+ :param: filename File name of the DBF
+ :return: List of rows
"""
db = Dbase()
db.open(filename)
diff --git a/sphinxutils.py b/sphinxutils.py
index 3889362..5615943 100644
--- a/sphinxutils.py
+++ b/sphinxutils.py
@@ -1,12 +1,12 @@
-"""
-Sphinx utils:
+"""Sphinx utils
-* ModuleGenerator: Generate a file that lists all the modules of a list of
- packages in order to pull all the docstring.
- /!\ This should not be used in a makefile to systematically generate
- sphinx documentation!
+ModuleGenerator: Generate a file that lists all the modules of a list of
+packages in order to pull all the docstring.
+This should not be used in a makefile to systematically generate sphinx
+documentation!
Typical usage:
+
>>> from logilab.common.sphinxutils import ModuleGenerator
>>> mgen = ModuleGenerator('logilab common', '/home/adim/src/logilab/common')
>>> mgen.generate('api_logilab_common.rst', exclude_dirs=('test',))