Esempio n. 1
0
def configure(globals_dict, settings_module_name=None):
    """
    Same as :func:`atelier.sphinxconf.configure` but with an
    additional positional argument `settings_module_name` (the name of
    a Django settings module).  If this argument is specified, call
    :meth:`lino.startup` with it.
    """
    if settings_module_name is not None:
        from lino import startup
        startup(settings_module_name)
        print("Django started with DJANGO_SETTINGS_MODULE={}.".format(settings_module_name))
        from django.conf import settings
        print(settings.SITE.welcome_text())
        # print(settings.SITE.diagnostic_report_rst())

        # os.environ['DJANGO_SETTINGS_MODULE'] = settings_module_name

        # # Trigger loading of Djangos model cache in order to avoid
        # # side effects that would occur when this happens later while
        # # importing one of the models modules.
        # from django.conf import settings
        # settings.SITE.startup()

        # globals_dict.update(
        #     template_bridge=str('lino.sphinxcontrib.DjangoTemplateBridge'))

    intersphinx_mapping = globals_dict.setdefault('intersphinx_mapping', dict())
    intersphinx_mapping['cg'] = ('https://community.lino-framework.org/', None)
    intersphinx_mapping['book'] = ('https://www.lino-framework.org/', None)
    return sphinxconf.configure(globals_dict)
Esempio n. 2
0
def configure(globals_dict, settings_module_name=None):
    """Same as :func:`atelier.sphinxconf.configure` but with an additional
    positional parameter `settings_module_name`.  If this is
    specified, call lino startup on it.

    """
    if settings_module_name is not None:
        from lino import startup
        startup(settings_module_name)

        # os.environ['DJANGO_SETTINGS_MODULE'] = settings_module_name

        # # Trigger loading of Djangos model cache in order to avoid
        # # side effects that would occur when this happens later while
        # # importing one of the models modules.
        # from django.conf import settings
        # settings.SITE.startup()

        globals_dict.update(
            template_bridge=str('atelier.sphinxconf.DjangoTemplateBridge'))
    return sphinxconf.configure(globals_dict)
Esempio n. 3
0
def configure(globals_dict, settings_module_name=None):
    """
    Same as :func:`atelier.sphinxconf.configure` but with an
    additional positional argument `settings_module_name` (the name of
    a Django settings module).  If this argument is specified, call
    :meth:`lino.startup` with it.
    """
    if settings_module_name is not None:
        from lino import startup
        startup(settings_module_name)

        # os.environ['DJANGO_SETTINGS_MODULE'] = settings_module_name

        # # Trigger loading of Djangos model cache in order to avoid
        # # side effects that would occur when this happens later while
        # # importing one of the models modules.
        # from django.conf import settings
        # settings.SITE.startup()

        # globals_dict.update(
        #     template_bridge=str('lino.sphinxcontrib.DjangoTemplateBridge'))
    return sphinxconf.configure(globals_dict)
Esempio n. 4
0
# that aren't pickleable (module imports are okay, they're removed automatically).
#
# All configuration values have a default value; values that are commented out
# serve to show the default value.

# from __future__ import unicode_literals

extlinks = {}
extensions = []
templates_path = []

# import lino
# from lino.sphinxcontrib import configure
from atelier import sphinxconf

sphinxconf.configure(
    globals())  #, 'lino_book.projects.min1.settings.doctests')

# from atelier.sphinxconf import interproject
# interproject.configure(globals())

# extensions += ['atelier.sphinxconf.blog']
# extensions += ['atelier.sphinxconf.complex_tables']
extensions += ['lino.sphinxcontrib.logo']
extensions += ['lino.sphinxcontrib.base']  # for tcname
# extensions += ['sphinxcontrib.taglist']
# extensions += ['sphinxcontrib.youtube']
extensions += ['sphinx.ext.inheritance_diagram']

# extensions += ['rinoh.frontend.sphinx'] # https://pypi.org/project/rinohtype/
# latex_elements = {
# 'papersize':'a4paper',
Esempio n. 5
0
# -*- coding: utf-8 -*-

import sys, os

from atelier.sphinxconf import configure
configure(globals(), 'lino_cosi.settings.demo')


extensions += ['lino.utils.actordoc']
extensions += ['lino.utils.screenshots']

#~ Trigger loading of Djangos model cache in order to avoid side effects that 
#~ would occur when this happens later while importing one of the models modules.
from django.conf import settings
#~ settings.SITE.startup()
settings.SITE.title = "Lino-Cosi Benutzerhandbuch"


# If your extensions are in another directory, add it here. If the directory
# is relative to the documentation root, use os.path.abspath to make it
# absolute, like shown here.
#sys.path.append(os.path.abspath('.'))

# General configuration
# ---------------------

# Add any Sphinx extension module names here, as strings. They can be extensions
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
#~ extensions = [
  #~ 'sphinx.ext.autodoc',
  #~ 'sphinx.ext.autosummary',
Esempio n. 6
0
# -*- coding: utf-8 -*-
#
# Sphinx documentation build configuration file, created by
# sphinx-quickstart on Thu Nov 13 11:09:54 2008.
#
# This file is execfile()d with the current directory set to its containing dir.
#
# The contents of this file are pickled, so don't put values in the namespace
# that aren't pickleable (module imports are okay, they're removed automatically).
#
# All configuration values have a default; values that are commented out
# serve to show the default.

extensions = []
from atelier.sphinxconf import configure
configure(globals())

extensions += ['atelier.sphinxconf.complex_tables']
extensions += ['sphinx.ext.autosummary']

import atelier

primary_domain = 'py'

# Add any paths that contain templates here, relative to this directory.
templates_path = ['.templates']

# The suffix of source filenames.
source_suffix = '.rst'

# The encoding of source files.
Esempio n. 7
0
# -*- coding: utf-8 -*-

import sys, os

from atelier.sphinxconf import configure
configure(globals(), 'lino_cosi.settings.demo')

extensions += ['lino.utils.actordoc']
extensions += ['lino.utils.screenshots']

#~ Trigger loading of Djangos model cache in order to avoid side effects that
#~ would occur when this happens later while importing one of the models modules.
from django.conf import settings
#~ settings.SITE.startup()
settings.SITE.title = "Lino-Cosi Benutzerhandbuch"

# If your extensions are in another directory, add it here. If the directory
# is relative to the documentation root, use os.path.abspath to make it
# absolute, like shown here.
#sys.path.append(os.path.abspath('.'))

# General configuration
# ---------------------

# Add any Sphinx extension module names here, as strings. They can be extensions
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
#~ extensions = [
#~ 'sphinx.ext.autodoc',
#~ 'sphinx.ext.autosummary',
# 'sphinx.ext.inheritance_diagram',
# 'sphinx.ext.todo',
Esempio n. 8
0
# -*- coding: utf-8 -*-
#
# This file is execfile()d with the current directory set to its containing dir.
#
# The contents of this file are pickled, so don't put values in the namespace
# that aren't pickleable (module imports are okay, they're removed automatically).
#
# All configuration values have a default; values that are commented out
# serve to show the default.

extensions = []

from atelier.sphinxconf import configure
configure(globals(), 'lino_cosi.projects.std.settings.doctests')

from django.conf import settings
settings.SITE.title = "Lino Cosi Reference Manual"

extensions += ['lino.sphinxcontrib.logo']

# General configuration
# ---------------------

# General information about the project.
project = settings.SITE.title
copyright = u'2012-2014, Luc Saffre'

# 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.
#
Esempio n. 9
0
# -*- coding: utf-8 -*-
#
# Sphinx documentation build configuration file, created by
# sphinx-quickstart on Thu Nov 13 11:09:54 2008.
#
# This file is execfile()d with the current directory set to its containing dir.
#
# The contents of this file are pickled, so don't put values in the namespace
# that aren't pickleable (module imports are okay, they're removed automatically).
#
# All configuration values have a default; values that are commented out
# serve to show the default.

import sys, os
from atelier.sphinxconf import configure
configure(globals(), 'settings')

#~ from unipath import Path
#~ DOCSDIR = Path(__file__).parent.absolute()
#~ sys.path.append(DOCSDIR)

import djangosite
#~ os.environ['DJANGO_SETTINGS_MODULE'] = 'djangosite.docs_settings'
#~ os.environ['DJANGO_SETTINGS_MODULE'] = 'settings'
#~ """
#~ Trigger loading of Djangos model cache in order to avoid side effects that 
#~ would occur when this happens later while importing one of the models modules.
#~ """
#~ from django.conf import settings

Esempio n. 10
0
#
# All configuration values have a default; values that are commented out
# serve to show the default.

from importlib import import_module
intersphinx_mapping = {}
for n in 'atelier lino_book lino_cosi'.split():
    m = import_module(n)
    n = n.replace('_', "")
    intersphinx_mapping[n] = (m.intersphinx_urls['docs'], None)

extlinks = {}
extensions = []

from atelier.sphinxconf import configure
configure(globals(), 'lino_voga.projects.roger.settings.doctests')
# configure(globals(), 'lino.projects.std.settings_test')

extensions += ['atelier.sphinxconf.blog']
extensions += ['lino.sphinxcontrib.actordoc']
extensions += ['lino.sphinxcontrib.logo']
# extensions += ['sphinxcontrib.taglist']

from django.conf import settings


# If your extensions are in another directory, add it here. If the directory
# is relative to the documentation root, use os.path.abspath to make it
# absolute, like shown here.
#sys.path.append(os.path.abspath('.'))
Esempio n. 11
0
# -*- coding: utf-8 -*-
#
# This file is execfile()d with the current directory set to its containing dir.
#
# The contents of this file are pickled, so don't put values in the namespace
# that aren't pickleable (module imports are okay, they're removed automatically).
#
# All configuration values have a default; values that are commented out
# serve to show the default.

extensions = []
extlinks = {}
intersphinx_mapping = {}

from atelier.sphinxconf import configure
configure(globals(), 'lino_cosi.projects.std.settings.doctests')

from django.conf import settings
settings.SITE.title = "Lino Cosi Documentation"

extensions += ['lino.sphinxcontrib.logo']
# extensions += ['sphinx.ext.autosummary']
# autodoc_default_flags = ['members']
autosummary_generate = True


from importlib import import_module
for n in 'atelier lino'.split():
    m = import_module(n)
    intersphinx_mapping[n] = (m.intersphinx_urls['docs'], None)
Esempio n. 12
0
# All configuration values have a default; values that are commented out
# serve to show the default.

import os
import sys
from unipath import Path
from atelier.sphinxconf import configure
import lino

sys.path.insert(0, Path(__file__).parent.absolute())

extlinks = {}
intersphinx_mapping = {}
extensions = []

configure(globals(), 'lino.projects.docs.settings.doctests')

language = 'en'

# extensions += ['sphinxcontrib.taglist']
extensions += ['atelier.sphinxconf.blog']
extensions += ['atelier.sphinxconf.complex_tables']
extensions += ['lino.sphinxcontrib.logo']
extensions += ['lino.sphinxcontrib.actordoc']
extensions += ['sphinx.ext.napoleon']

extensions += ['atelier.sphinxconf.sigal_image']
sigal_base_url = 'http://sigal.saffre-rumma.net'

if False:
    extensions += ['sphinxcontrib.blockdiag']
Esempio n. 13
0
import os
import sys
from unipath import Path
from atelier.sphinxconf import configure

import lino
import lino_xl
import lino_book

sys.path.insert(0, Path(__file__).parent.absolute())

extlinks = {}
intersphinx_mapping = {}
extensions = []

configure(globals(), 'lino_book.projects.max.settings.doctests')

language = 'en'

# extensions += ['sphinxcontrib.taglist']
extensions += ['atelier.sphinxconf.blog']
extensions += ['atelier.sphinxconf.complex_tables']
extensions += ['lino.sphinxcontrib.logo']
extensions += ['lino.sphinxcontrib.actordoc']
# extensions += ['sphinx.ext.napoleon']

extensions += ['atelier.sphinxconf.sigal_image']
sigal_base_url = 'http://sigal.saffre-rumma.net'

extensions += ['lino.sphinxcontrib.help_texts_extractor']
help_texts_builder_targets = {
Esempio n. 14
0
File: conf.py Progetto: khchine5/noi
# -*- coding: utf-8 -*-
#
# This file is execfile()d with the current directory set to its containing dir.
#
# The contents of this file are pickled, so don't put values in the namespace
# that aren't pickleable (module imports are okay, they're removed automatically).
#
# All configuration values have a default; values that are commented out
# serve to show the default.

extensions = []
extlinks = {}

from atelier.sphinxconf import configure
configure(globals(), 'lino_noi.projects.team.settings.doctests')
# configure(globals(), 'lino_book.projects.min1.settings.doctests')

extlinks.update(ticket=('http://bugs.lino-framework.org/tickets/Ticket/%s', '#'))

extensions += ['lino.sphinxcontrib.logo']

extensions += ['lino.sphinxcontrib.help_texts_extractor']
help_texts_builder_targets = {
    'lino_noi.': 'lino_noi.lib.noi'
}

from django.conf import settings
# settings.SITE.title = "Lino Noi"

intersphinx_mapping = {}
from importlib import import_module
Esempio n. 15
0
# -*- coding: utf-8 -*-
#
# This file is execfile()d with the current directory set to its containing dir.
#
# The contents of this file are pickled, so don't put values in the namespace
# that aren't pickleable (module imports are okay, they're removed automatically).
#
# All configuration values have a default; values that are commented out
# serve to show the default.

extensions = []

from atelier.sphinxconf import configure
configure(globals(), 'lino_cosi.settings.doctests')

from django.conf import settings
settings.SITE.title = "Lino Cosi Reference Manual"

extensions += ['lino.sphinxcontrib.logo']


# General configuration
# ---------------------

# General information about the project.
project = settings.SITE.title
copyright = u'2012-2014, Luc Saffre'

# 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.
Esempio n. 16
0
# -*- coding: utf-8 -*-
#
# This file is execfile()d with the current directory set to its containing dir.
#
# The contents of this file are pickled, so don't put values in the namespace
# that aren't pickleable (module imports are okay, they're removed automatically).
#
# All configuration values have a default; values that are commented out
# serve to show the default.

extensions = []
extlinks = {}
intersphinx_mapping = {}

from atelier.sphinxconf import configure
configure(globals(), 'lino_extjs6.projects.mysite.settings.demo')

from django.conf import settings
settings.SITE.title = "Lino ExtJS 6 Documentation"

extensions += ['lino.sphinxcontrib.logo']
# extensions += ['sphinx.ext.autosummary']
# autodoc_default_flags = ['members']
autosummary_generate = True


from importlib import import_module
for n in 'atelier lino'.split():
    m = import_module(n)
    intersphinx_mapping[n] = (m.intersphinx_urls['docs'], None)
Esempio n. 17
0
# sphinx-quickstart on Thu Nov 13 11:09:54 2008.
#
# This file is execfile()d with the current directory set to its containing dir.
#
# The contents of this file are pickled, so don't put values in the namespace
# that aren't pickleable (module imports are okay, they're removed automatically).
#
# All configuration values have a default; values that are commented out
# serve to show the default.

import sys, os
from unipath import Path

from atelier.sphinxconf import configure

configure(globals(), "settings")

if False:
    import settings

    if Path(settings.__file__).parent != Path(__file__).parent:
        raise Exception(
            """
Oops: `import settings` finds a settings module in %s.
See `blog/2013/0812.rst` and clean up your Python path!"""
            % Path(settings.__file__).parent
        )

extensions += ["atelier.sphinxconf.blog"]

Esempio n. 18
0
#
# The contents of this file are pickled, so don't put values in the namespace
# that aren't pickleable (module imports are okay, they're removed automatically).
#
# All configuration values have a default; values that are commented out
# serve to show the default.

# from __future__ import unicode_literals

import sys, os

extlinks = {}
extensions = []

from atelier.sphinxconf import configure
configure(globals(), 'lino_welfare.projects.std.settings.doctests')

# Building the docs for Lino Welfare requires a development version of
# Lino because we often use :rst:role:`ref` for refering to general
# Lino docs.


from importlib import import_module
intersphinx_mapping = {}
for n in 'atelier lino_book lino_cosi'.split():
    m = import_module(n)
    n = n.replace('_', "")
    intersphinx_mapping[n] = (m.intersphinx_urls['docs'], None)

# from atelier.sphinxconf import interproject
# interproject.configure(globals())
Esempio n. 19
0
# -*- coding: utf-8 -*-
#
# Sphinx documentation build configuration file, created by
# sphinx-quickstart on Thu Nov 13 11:09:54 2008.
#
# This file is execfile()d with the current directory set to its containing dir.
#
# The contents of this file are pickled, so don't put values in the namespace
# that aren't pickleable (module imports are okay, they're removed automatically).
#
# All configuration values have a default; values that are commented out
# serve to show the default.

extensions = []
from atelier.sphinxconf import configure
configure(globals())

extensions += ['atelier.sphinxconf.complex_tables']
extensions += ['sphinx.ext.autosummary']

import atelier

# primary_domain = 'py'

# Add any paths that contain templates here, relative to this directory.
templates_path = ['.templates']

# The suffix of source filenames.
# source_suffix = '.rst'

# The encoding of source files.
Esempio n. 20
0
# -*- coding: utf-8 -*-
import sys, os
from atelier.sphinxconf import configure
configure(globals(), settings_module_name='settings')

import north

# Add any paths that contain templates here, relative to this directory.
templates_path = ['.templates']

# General information about the project.
project = "north"
copyright = '2002-2014, Luc Saffre'

# 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.
#

# The full version, including alpha/beta/rc tags.
#~ release = file(os.path.join(os.path.dirname(__file__),'..','VERSION')).read().strip()
release = north.__version__

# The short X.Y version.
version = '.'.join(release.split('.')[:2])
#~ version = lino.__version__

#~ print version, release

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Esempio n. 21
0
File: conf.py Progetto: sandeez/lino
# All configuration values have a default; values that are commented out
# serve to show the default.

import os
import sys
from unipath import Path
from atelier.sphinxconf import configure
import lino

sys.path.insert(0, Path(__file__).parent.absolute())

extlinks = {}
intersphinx_mapping = {}
extensions = []

configure(globals(), 'lino.projects.docs.settings.doctests')

language = 'en'

# extensions += ['sphinxcontrib.taglist']
extensions += ['atelier.sphinxconf.blog']
extensions += ['atelier.sphinxconf.complex_tables']
extensions += ['lino.sphinxcontrib.logo']
extensions += ['lino.sphinxcontrib.actordoc']
extensions += ['sphinx.ext.napoleon']

extensions += ['atelier.sphinxconf.sigal_image']
sigal_base_url = 'http://sigal.saffre-rumma.net'

if False:
    extensions += ['sphinxcontrib.blockdiag']
Esempio n. 22
0
# that aren't pickleable (module imports are okay, they're removed automatically).
#
# All configuration values have a default; values that are commented out
# serve to show the default.

import sys, os

from importlib import import_module
intersphinx_mapping = {}
for n in 'atelier lino'.split():
    m = import_module(n)
    intersphinx_mapping[n] = (m.intersphinx_urls['docs'], None)

extensions = []
from atelier.sphinxconf import configure
configure(globals(), 'lino_patrols.settings.demo')


from django.conf import settings
settings.SITE.title = "Lino Patrols Reference Manual"


# If your extensions are in another directory, add it here. If the directory
# is relative to the documentation root, use os.path.abspath to make it
# absolute, like shown here.
#sys.path.append(os.path.abspath('.'))

# General configuration
# ---------------------

# Add any Sphinx extension module names here, as strings. They can be extensions