aboutsummaryrefslogtreecommitdiffstats
path: root/doc/conf.py
diff options
context:
space:
mode:
author1138-4EB <1138-4EB@users.noreply.github.com>2019-08-31 17:32:35 +0200
committertgingold <tgingold@users.noreply.github.com>2019-08-31 17:32:35 +0200
commitb124c3926b05d7d0770989330039518c391f73cf (patch)
treeff417a3940604ca8be2f005ae0d93302afcd4519 /doc/conf.py
parent6852a8f2b79f87ffb523f0aa4157f23540818887 (diff)
downloadghdl-b124c3926b05d7d0770989330039518c391f73cf.tar.gz
ghdl-b124c3926b05d7d0770989330039518c391f73cf.tar.bz2
ghdl-b124c3926b05d7d0770989330039518c391f73cf.zip
[doc] Update section 'Getting GHDL' (#906)
* doc: fix version extraction from 'configure' * doc: update section 'Getting GHDL' * readme: update
Diffstat (limited to 'doc/conf.py')
-rw-r--r--doc/conf.py30
1 files changed, 13 insertions, 17 deletions
diff --git a/doc/conf.py b/doc/conf.py
index efa30f23e..014cbd13b 100644
--- a/doc/conf.py
+++ b/doc/conf.py
@@ -14,17 +14,10 @@
import sys, os, shlex, re, subprocess
-# http://docs.readthedocs.io/en/latest/getting_started.html#in-markdown
-from recommonmark.parser import CommonMarkParser
-source_parsers = { '.md': CommonMarkParser, }
-
# If extensions (or modules to document with autodoc) are in another directory,
# 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.
sys.path.insert(0, os.path.abspath('.'))
-# sys.path.insert(0, os.path.abspath('../py'))
-sys.path.insert(0, os.path.abspath('_extensions'))
-# sys.path.insert(0, os.path.abspath('_themes/sphinx_rtd_theme'))
# -- General configuration ------------------------------------------------
@@ -36,6 +29,7 @@ needs_sphinx = '1.5'
# ones.
extensions = [
# Standard Sphinx extensions
+ 'recommonmark',
'sphinx.ext.extlinks',
'sphinx.ext.intersphinx',
'sphinx.ext.todo',
@@ -55,9 +49,11 @@ extensions = [
templates_path = ['_templates', '_themes']
# The suffix(es) of source filenames.
-# You can specify multiple suffix as a list of string:
-# source_suffix = ['.rst', '.md']
-source_suffix = ['.rst', '.md']
+source_suffix = {
+ '.rst': 'restructuredtext',
+ #'.txt': 'markdown',
+ '.md': 'markdown',
+}
# The encoding of source files.
#source_encoding = 'utf-8-sig'
@@ -67,21 +63,22 @@ master_doc = 'index'
# General information about the project.
project = u'GHDL'
-copyright = u'2015-2017, Tristan Gingold and contributors'
+copyright = u'2002-2019, Tristan Gingold and contributors'
author = u'Tristan Gingold and contributors'
# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
# built documents.
-#
+
try:
with open('../configure') as verin:
for line in verin:
- line = re.findall(r'ghdl_version=\"(.+)\"', line)
+ line = re.findall(r'ghdl_version=\"([0-9].+)\"', line)
if line:
version=line[0]
-except Exception, e:
- print "cannot extract version: %s" % e
+ break
+except Exception as e:
+ print('cannot extract version: %s' % e)
version = "latest"
pass
@@ -89,7 +86,6 @@ release = version # The full version, including alpha/beta/rc tags.
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
-#
# This is also used if you do content translation via gettext catalogs.
# Usually you set "language" from the command line for these cases.
language = None
@@ -334,7 +330,7 @@ texinfo_documents = [
# ==============================================================================
intersphinx_mapping = {
'python': ('https://docs.python.org/3.6/', None),
- 'poc': ('http://poc-library.readthedocs.io/en/release', None),
+ 'poc': ('https://poc-library.readthedocs.io/en/release', None),
# 'ghdl': ('http://ghdl.readthedocs.io/en/latest', None)
}