<commit_before># -*- coding: utf-8 -*-
#
# StackStorm documentation build configuration file, created by
# sphinx-quickstart on Tue Oct  7 21:52:49 2014.
#
# This file is execfile()d with the current directory set to its
# containing dir.
#
# Note that not all possible configuration values are present in this
# autogenerated file.
#
# All configuration values have a default; values that are commented out
# serve to show the default.

import sys
import os
import glob

BASE_DIR = os.path.dirname(os.path.abspath(__file__))
ROOT_DIR = os.path.abspath(os.path.join(BASE_DIR, '../../'))

# Include Python modules for all the st2components
st2_components_paths = glob.glob(ROOT_DIR + '/st2*')
for module_path in st2_components_paths:
    sys.path.append(module_path)

# 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('./_themes'))

from st2common import __version__

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

# If your documentation needs a minimal Sphinx version, state it here.
# needs_sphinx = '1.0'

# 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.intersphinx',
    'sphinx.ext.viewcode',
    'sphinx.ext.todo',
    'sphinx.ext.extlinks',

    # Add theme as extension so sitemap.xml is generated
    'sphinx_rtd_theme'
]

# 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.
# source_encoding = 'utf-8-sig'

# The master toctree document.
master_doc = 'index'

# General information about the project.
project = u'StackStorm'
copyright = u'2014, StackStorm Inc'

# 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 __version__ is 0.8.1 or 0.9dev
# the version is short 0.8 version, to refer docs.
version = '.'.join(__version__.split('.')[:2])
# The full version, including alpha/beta/rc tags.
release = __version__
# The complete list of current StackStorm versions.
release_versions = ['1.1', '0.13', '0.12', '0.11', '0.9', '0.8']


def previous_version(ver):
    if ver.endswith('dev'):
        return release_versions[0]
    major_minor = '.'.join(ver.split('.')[:2])
    if major_minor in release_versions:
        idx = release_versions.index(major_minor)
        if idx + 1 < len(release_versions):
            return release_versions[idx + 1]
    # Better than broken return some value. Coontrol flow should not reach this point.
    return release_versions[0]

# The short versions of two previous releases, e.g. 0.8 and 0.7
version_minus_1 = previous_version(version)
version_minus_2 = previous_version(version_minus_1)

# extlink configurator sphinx.ext.extlinks
extlinks = {
    'github_st2': ('https://github.com/StackStorm/st2/blob/master/%s', None),
    'github_mistral': ('https://github.com/StackStorm/mistral/blob/master/%s', None),
    'github_contrib':
        ('https://github.com/StackStorm/st2contrib/blob/master/%s', None),
    'github_devenv': ('https://github.com/StackStorm/devenv/blob/master/%s', None),
    'github_st2web': ('https://github.com/StackStorm/st2web/blob/master/%s', None),<commit_msg>Fix missing 1.2 version in selector<commit_after># -*- coding: utf-8 -*-
#
# StackStorm documentation build configuration file, created by
# sphinx-quickstart on Tue Oct  7 21:52:49 2014.
#
# This file is execfile()d with the current directory set to its
# containing dir.
#
# Note that not all possible configuration values are present in this
# autogenerated file.
#
# All configuration values have a default; values that are commented out
# serve to show the default.

import sys
import os
import glob

BASE_DIR = os.path.dirname(os.path.abspath(__file__))
ROOT_DIR = os.path.abspath(os.path.join(BASE_DIR, '../../'))

# Include Python modules for all the st2components
st2_components_paths = glob.glob(ROOT_DIR + '/st2*')
for module_path in st2_components_paths:
    sys.path.append(module_path)

# 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('./_themes'))

from st2common import __version__

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

# If your documentation needs a minimal Sphinx version, state it here.
# needs_sphinx = '1.0'

# 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.intersphinx',
    'sphinx.ext.viewcode',
    'sphinx.ext.todo',
    'sphinx.ext.extlinks',

    # Add theme as extension so sitemap.xml is generated
    'sphinx_rtd_theme'
]

# 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.
# source_encoding = 'utf-8-sig'

# The master toctree document.
master_doc = 'index'

# General information about the project.
project = u'StackStorm'
copyright = u'2014, StackStorm Inc'

# 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 __version__ is 0.8.1 or 0.9dev
# the version is short 0.8 version, to refer docs.
version = '.'.join(__version__.split('.')[:2])
# The full version, including alpha/beta/rc tags.
release = __version__
# The complete list of current StackStorm versions.
release_versions = ['1.2', '1.1', '0.13', '0.12', '0.11', '0.9', '0.8']


def previous_version(ver):
    if ver.endswith('dev'):
        return release_versions[0]
    major_minor = '.'.join(ver.split('.')[:2])
    if major_minor in release_versions:
        idx = release_versions.index(major_minor)
        if idx + 1 < len(release_versions):
            return release_versions[idx + 1]
    # Better than broken return some value. Control flow should not reach this point.
    return "unknown"

# The short versions of two previous releases, e.g. 0.8 and 0.7
version_minus_1 = previous_version(version)
version_minus_2 = previous_version(version_minus_1)

# extlink configurator sphinx.ext.extlinks
extlinks = {
    'github_st2': ('https://github.com/StackStorm/st2/blob/master/%s', None),
    'github_mistral': ('https://github.com/StackStorm/mistral/blob/master/%s', None),
    'github_contrib':
        ('https://github.com/StackStorm/st2contrib/blob/master/%s', None),
    'github_devenv': ('https://github.com/StackStorm/devenv/blob/master/%s', None),
    'github_st2web': ('https://github.com/StackStorm/st2web/blob/master/%s', None),
{'fraction_non_alphanumeric': 0.13020115734362084, 'fraction_numerical': 0.01832460732984293, 'mean_word_length': 3.810470510271703, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 10, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6157809', 'n_tokens_mistral': 2337, 'n_tokens_neox': 2250, 'n_words': 717}