Skip to content

Commit

Permalink
Merge pull request #81 from TheFriendlyCoder/google
Browse files Browse the repository at this point in the history
Fixes #76 updated google style docs
  • Loading branch information
TheFriendlyCoder committed Jul 19, 2020
2 parents 351fd01 + bfdaed0 commit 0b2d72a
Show file tree
Hide file tree
Showing 38 changed files with 355 additions and 504 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Expand Up @@ -12,6 +12,8 @@ htmlcov/
.tox/
.coverage
docs/_*
docs/api/*
htmldocs/*
.pytest_cache/

# Virtual environmenments
Expand Down
20 changes: 20 additions & 0 deletions .readthedocs.yml
@@ -0,0 +1,20 @@
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Build documentation in the docs/ directory with Sphinx
sphinx:
configuration: docs/conf.py
fail_on_warning: true

# Optionally build your docs in additional formats such as PDF
formats:
- pdf

# Optionally set the version of Python and requirements required to build your docs
python:
version: 3.7
install:
- requirements: docs/requirements.txt
5 changes: 2 additions & 3 deletions .travis.yml
Expand Up @@ -4,11 +4,10 @@ python:
- 3.5
- 3.7
- 3.8
- pypy3.5
#- pypy3.5

install:
# NOTE: we had to add coverage package at a pinned version to fix pypy3 builds
- pip install tox tox-factor wheel python-coveralls coverage==4.5.4
- pip install tox tox-factor wheel python-coveralls

script:
- echo $TRAVIS_PYTHON_VERSION
Expand Down
20 changes: 17 additions & 3 deletions docs/conf.py
Expand Up @@ -15,6 +15,7 @@
import ast
import os
import sys
import sphinx_rtd_theme

# 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
Expand Down Expand Up @@ -44,6 +45,13 @@
# The full version, including alpha/beta/rc tags.
release = version

# Configure automatic API documentation
apidoc_module_dir = _proj_dir
apidoc_output_dir = os.path.join(_base_path, "api")
apidoc_separate_modules = True
napoleon_numpy_docstring = False
autoclass_content = "both"
napoleon_include_special_with_doc = False

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

Expand All @@ -57,7 +65,11 @@
extensions = [
'sphinx.ext.autodoc',
'sphinx.ext.intersphinx',
'sphinx.ext.todo',
'sphinx.ext.viewcode',
'sphinxcontrib.apidoc',
'sphinx.ext.napoleon',
'sphinx_rtd_theme',
]

# Add any paths that contain templates here, relative to this directory.
Expand Down Expand Up @@ -93,18 +105,20 @@
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
html_theme = 'alabaster'
html_theme = 'sphinx_rtd_theme'

# 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 = {}
html_theme_options = {
"style_external_links": True,
}

# 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_static_path = []

# Custom sidebar templates, must be a dictionary that maps document names
# to template names.
Expand Down
7 changes: 0 additions & 7 deletions docs/friendlypins.api.rst

This file was deleted.

7 changes: 0 additions & 7 deletions docs/friendlypins.board.rst

This file was deleted.

7 changes: 0 additions & 7 deletions docs/friendlypins.headers.rst

This file was deleted.

7 changes: 0 additions & 7 deletions docs/friendlypins.pin.rst

This file was deleted.

31 changes: 0 additions & 31 deletions docs/friendlypins.rst

This file was deleted.

7 changes: 0 additions & 7 deletions docs/friendlypins.scripts.fpins.rst

This file was deleted.

18 changes: 0 additions & 18 deletions docs/friendlypins.scripts.rst

This file was deleted.

7 changes: 0 additions & 7 deletions docs/friendlypins.scripts.webp2jpeg.rst

This file was deleted.

7 changes: 0 additions & 7 deletions docs/friendlypins.thumbnail.rst

This file was deleted.

7 changes: 0 additions & 7 deletions docs/friendlypins.user.rst

This file was deleted.

7 changes: 0 additions & 7 deletions docs/friendlypins.utils.console_actions.rst

This file was deleted.

7 changes: 0 additions & 7 deletions docs/friendlypins.utils.rest_io.rst

This file was deleted.

18 changes: 0 additions & 18 deletions docs/friendlypins.utils.rst

This file was deleted.

7 changes: 0 additions & 7 deletions docs/friendlypins.version.rst

This file was deleted.

2 changes: 1 addition & 1 deletion docs/index.rst
Expand Up @@ -42,7 +42,7 @@ Welcome to friendlypins' documentation!
:maxdepth: 1
:caption: Contents:

modules
api/modules

Overview
========
Expand Down
7 changes: 0 additions & 7 deletions docs/modules.rst

This file was deleted.

27 changes: 27 additions & 0 deletions docs/requirements.txt
@@ -0,0 +1,27 @@
alabaster==0.7.12
Babel==2.8.0
certifi==2020.6.20
chardet==3.0.4
docutils==0.16
idna==2.10
imagesize==1.2.0
Jinja2==2.11.2
MarkupSafe==1.1.1
packaging==20.4
pbr==5.4.5
Pygments==2.6.1
pyparsing==2.4.7
pytz==2020.1
requests==2.24.0
six==1.15.0
snowballstemmer==2.0.0
Sphinx==3.1.2
sphinx-rtd-theme==0.5.0
sphinxcontrib-apidoc==0.3.0
sphinxcontrib-applehelp==1.0.2
sphinxcontrib-devhelp==1.0.2
sphinxcontrib-htmlhelp==1.0.3
sphinxcontrib-jsmath==1.0.1
sphinxcontrib-qthelp==1.0.3
sphinxcontrib-serializinghtml==1.1.4
urllib3==1.25.9
13 changes: 12 additions & 1 deletion lock.sh
Expand Up @@ -10,9 +10,20 @@
# referenced by the tox.ini config file at build time.
# Any changes to this pattern will need to be reflected
# there as well.
rm -rf src/*.egg-info
rm -rf build
rm -rf dist
virtualenv -p `which python3` tmp
source ./tmp/bin/activate
pip install -e ".[dev]"
pip freeze --exclude-editable > ./tests/python3.reqs
pip freeze --exclude-editable > ./requirements.txt
deactivate
rm -rf tmp

# Update dependencies specific for ReadTheDocs
virtualenv -p `which python3` tmp
source ./tmp/bin/activate
pip install sphinx sphinxcontrib-apidoc sphinx-rtd-theme
pip freeze > ./docs/requirements.txt
deactivate
rm -rf tmp
1 change: 1 addition & 0 deletions project.prop
Expand Up @@ -19,6 +19,7 @@
"pylint",
"sphinx",
"sphinxcontrib-apidoc",
"sphinx-rtd-theme",
"tox",
"tox-factor"
],
Expand Down
File renamed without changes.
1 change: 1 addition & 0 deletions tests/python3.reqs → requirements.txt
Expand Up @@ -42,6 +42,7 @@ requests-toolbelt==0.9.1
six==1.15.0
snowballstemmer==2.0.0
Sphinx==3.1.2
sphinx-rtd-theme==0.5.0
sphinxcontrib-apidoc==0.3.0
sphinxcontrib-applehelp==1.0.2
sphinxcontrib-devhelp==1.0.2
Expand Down
5 changes: 0 additions & 5 deletions setup.cfg
@@ -1,7 +1,2 @@
[build_sphinx]
source-dir = docs
build-dir = build/sphinx
all-files = 1

[bdist_wheel]
universal = 1

0 comments on commit 0b2d72a

Please sign in to comment.