Commit 948d2796 authored by Boris Budini's avatar Boris Budini 🛡

New CI

parent a000dd77
Pipeline #587 passed with stages
in 1 minute and 20 seconds
stages:
- build
- deploy
build:html:
image: kominoshja/c68-sphinx:latest
stage: build
script:
- git clone https://github.com/Blendify/sphinx-bootstrap-directives.git
- cd sphinx-bootstrap-directives
- python setup.py build
- python setup.py install
- cd docs
- rm -Rf source
- cd ../..
- git clone https://git.collective68.tech/works/read-the-docs/collective68/offline-version.git _themes/sphinx_rtd_theme
- make html
- cd _build/html
- rm -rf objects.inv .doctrees _raw_sources sphinx-bootstrap-directives .buildinfo
- zip -r documentation.zip .
- mv documentation.zip ../..
artifacts:
paths:
- documentation.zip
pages:
image: kominoshja/c68-sphinx:latest
stage: deploy
script:
- apk --no-cache add py-pip python-dev git make
- pip install sphinx guzzle_sphinx_theme recommonmark markdown m2r sphinx_rtd_theme
- git clone https://github.com/Blendify/sphinx-bootstrap-directives.git
- cd sphinx-bootstrap-directives
- python setup.py build
......@@ -9,25 +34,16 @@ pages:
- cd docs
- rm -Rf source
- cd ../..
- git clone https://git.collective68.tech/works/read-the-docs/collective68/online-version.git _themes/sphinx_rtd_theme
- make html
- mv _build/html/ public/
- sphinx-build -b pdf . _build/html/
- mv _build/html public
- mv documentation.zip public
- rm -rf public/objects.inv public/.doctrees public/_raw_sources public/sphinx-bootstrap-directives public/.buildinfo
dependencies:
- build:html
artifacts:
paths:
- public
only:
- master
#compile_pdf:
# image: aergus/latex
# script:
# - wget -L https://bootstrap.pypa.io/get-pip.py
# - python get-pip.py
# - pip install sphinx guzzle_sphinx_theme recommonmark markdown m2r sphinx_rtd_theme
# - make latex
# - make latexpdf -
# - mv _build/latex/FabAcademy2018.pdf FabAcademy2018.pdf
# artifacts:
# paths:
# - FabAcademy2018.pdf
# only:
# - master
\ No newline at end of file
......@@ -11,48 +11,65 @@ sys.path.insert(0, os.path.abspath(os.path.join('../..', 'sphinx-bootstrap-direc
# GENERAL CONFIGURATION
# -----------------------------------------------------------------------------
project = u'General Documentation'
project = u'Collective68'
copyright = u''
authors = u"Collective68"
authors = u""
master_doc = 'index'
templates_path = ['_templates']
extensions = [
'm2r',]
extensions = ['m2r', 'rst2pdf.pdfbuilder', 'sphinxprettysearchresults']
source_suffix = ['.rst', '.md']
version = '0.1.0'
version = '1.0.0'
exclude_patterns = ['_build']
github_doc_root = 'https://git.collective68.tech/docs/general'
# -----------------------------------------------------------------------------
# HTML THEMES SETTINGS
# -----------------------------------------------------------------------------
import sphinx_rtd_theme
html_theme = 'sphinx_rtd_theme'
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
html_theme_path = ["_themes"]
# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
#
html_theme_options = {
# 'canonical_url': 'https://git.collective68.tech/docs/general',
'display_version': False,
'collapse_navigation': True
'style_external_links': True,
'sticky_navigation': True,
'canonical_url': '',
'logo_only': True
}
html_title = u'Collective68 Documentation'
# Add any paths that contain custom themes here, relative to this directory.
# html_theme_path = []
# The name for this set of Sphinx documents.
# "<project> v<release> documentation" by default.
#
html_title = u'Collective68'
html_short_title = u'C68 Documentation'
# A shorter title for the navigation bar. Default is the same as html_title.
#
# html_short_title = None
html_logo = "_static/logo.png"
# The name of an image file (relative to this directory) to place at the top
# of the sidebar.
#
# html_logo = None
html_favicon = None
# The name of an image file (relative to this directory) to use as a favicon of
# the docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
# pixels large.
#
# html_favicon = None
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']
html_context = {
'source_url_prefix': "https://git.collective68.tech/docs/general/blob/master/",
'display_gitlab': False
}
# Insert custom js and css locations here
def setup(app):
app.add_javascript('_static/js/custom.js')
# Add any extra paths that contain custom files (such as robots.txt or
# .htaccess) here, relative to this directory. These files are copied
......@@ -64,7 +81,7 @@ html_context = {
# bottom, using the given strftime format.
# The empty string is equivalent to '%b %d, %Y'.
#
html_last_updated_fmt = '%b %d, %Y'
html_last_updated_fmt = '%H:%M:%S %m/%d/%y'
# If true, SmartyPants will be used to convert quotes and dashes to
# typographically correct entities.
......@@ -86,23 +103,13 @@ html_last_updated_fmt = '%b %d, %Y'
# If false, no index is generated.
#
# html_use_index = True
#html_use_index = True
# If true, the index is split into individual pages for each letter.
#
# html_split_index = False
# If true, links to the reST sources are added to the pages.
#
#html_show_sourcelink = True
# If true, "Created using Sphinx" is shown in the HTML footer. Default is True.
#
html_show_sphinx = True
# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True.
#
html_show_copyright = False
# If true, an OpenSearch description file will be output, and all pages will
# contain a <link> tag referring to it. The value of this option must be the
......@@ -118,7 +125,7 @@ html_show_copyright = False
# 'da', 'de', 'en', 'es', 'fi', 'fr', 'hu', 'it', 'ja'
# 'nl', 'no', 'pt', 'ro', 'ru', 'sv', 'tr', 'zh'
#
html_search_language = 'en'
# html_search_language = 'en'
# A dictionary with options for the search language support, empty by default.
# 'ja' uses this config value.
......@@ -132,36 +139,14 @@ html_search_language = 'en'
# html_search_scorer = 'scorer.js'
# Output file base name for HTML help builder.
htmlhelp_basename = 'Collective68 Documentation'
htmlhelp_basename = 'SphinxExampleProjectdoc'
# ------------------------------------------------------------------------------
# OPTIONS FOR: LATEX OUTPUT
# OPTIONS FOR: PDF Output
# ------------------------------------------------------------------------------
latex_elements = {
# The paper size ("letterpaper" or "a4paper").
"papersize": "a4paper",
# The font size ("10pt", "11pt" or "12pt").
# "pointsize": "10pt",
# Additional stuff for the LaTeX preamble.
# "preamble": "",
}
# Grouping the document tree into LaTeX files. List of tuples
# (source start file, target name, title, author, documentclass [howto/manual]).
latex_documents = [
("index", "C68Docs.tex", u"Collective68 documentation", authors, "manual"),
]
# latex_logo = None
latex_show_urls = True
def setup(app):
app.add_transform(AutoStructify)
app.add_stylesheet('css/custom.css')
app.add_javascript('js/custom.js')
pdf_documents = [('index', u'documentation', u'DOCUMENT TITLE', u'Collective68'),]
pdf_use_index = False
pdf_use_coverpage = False
pdf_stylesheets = ['sphinx','kerning','a4']
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment