Add paths from pyams packages into conf.py to generate autodoc dev-dc
authorDamien Correia
Wed, 04 Apr 2018 10:33:01 +0200
branchdev-dc
changeset 35 475ba5e42666
parent 34 f234f01d54f9
child 36 55a05201f18c
Add paths from pyams packages into conf.py to generate autodoc
src/source/conf.py
--- a/src/source/conf.py	Tue Apr 03 18:17:48 2018 +0200
+++ b/src/source/conf.py	Wed Apr 04 10:33:01 2018 +0200
@@ -17,8 +17,45 @@
 # add these directories to sys.path here. If the directory is relative to the
 # documentation root, use os.path.abspath to make it absolute, like shown here.
 #
-# import sys
-# sys.path.insert(0, '/var/local/env/pycharm/lib/python3.5/site-packages')
+import sys
+#sys.path.insert(0, '/var/local/env/pycharm/lib/python3.5/site-packages')
+
+import os
+
+prefix_path = os.path.abspath('../../../') + os.path.sep
+sys.path[0:0] = list(map(lambda x: prefix_path + x,
+                         [
+                             'pyams_alchemy/src',
+                             'pyams_cache/src',
+                             'pyams_catalog/src',
+                             'pyams_content/src',
+                             'pyams_content_es/src',
+                             'pyams_default_theme/src',
+                             'pyams_file/src',
+                             'pyams_form/src',
+                             'pyams_gis/src',
+                             'pyams_i18n/src',
+                             'pyams_ldap/src',
+                             'pyams_mail/src',
+                             'pyams_media/src',
+                             'pyams_notify/src',
+                             'pyams_notify_ws/src',
+                             'pyams_pagelet/src',
+                             'pyams_portal/src',
+                             'pyams_scheduler/src',
+                             'pyams_security/src',
+                             'pyams_sequence/src',
+                             'pyams_skin/src',
+                             'pyams_template/src',
+                             'pyams_thesaurus/src',
+                             'pyams_utils/src',
+                             'pyams_viewlet/src',
+                             'pyams_workflow/src',
+                             'pyams_zmi/src',
+                             'pyams_zmq/src',
+                             'pyams_zodbbrowser/src',
+                         ])
+                     )
 
 # -- General configuration ------------------------------------------------