[POC] discard dev doc if odoo directory is not found
This commit is contained in:
parent
610f2abef3
commit
53389b1992
8
conf.py
8
conf.py
@ -9,6 +9,9 @@ sys.path.insert(0,
|
|||||||
os.path.abspath(
|
os.path.abspath(
|
||||||
os.path.join(DIR, '_extensions')))
|
os.path.join(DIR, '_extensions')))
|
||||||
|
|
||||||
|
build_dev_doc = False
|
||||||
|
if os.path.exists('../odoo/odoo-bin'):
|
||||||
|
build_dev_doc = True
|
||||||
# put current odoo's source on PYTHONPATH for autodoc
|
# put current odoo's source on PYTHONPATH for autodoc
|
||||||
sys.path.insert(0, os.path.abspath(os.path.join(DIR, '../odoo')))
|
sys.path.insert(0, os.path.abspath(os.path.join(DIR, '../odoo')))
|
||||||
|
|
||||||
@ -72,12 +75,15 @@ today_fmt = '%B %d, %Y'
|
|||||||
# directories to ignore when looking for source files.
|
# directories to ignore when looking for source files.
|
||||||
exclude_patterns = [
|
exclude_patterns = [
|
||||||
# translations
|
# translations
|
||||||
'locale',
|
'user/locale',
|
||||||
'README.*',
|
'README.*',
|
||||||
# virtualenv
|
# virtualenv
|
||||||
'bin', 'include', 'lib',
|
'bin', 'include', 'lib',
|
||||||
]
|
]
|
||||||
|
|
||||||
|
if not build_dev_doc:
|
||||||
|
exclude_patterns += ["developer"]
|
||||||
|
|
||||||
# The specifications of redirect rules used by the redirects extension.
|
# The specifications of redirect rules used by the redirects extension.
|
||||||
redirects_file = 'redirects.txt'
|
redirects_file = 'redirects.txt'
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user