Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: reorganize and extend documentation #4325

Merged
merged 20 commits into from
May 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion doc/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1 +0,0 @@
exports_files(["PathPolicy.md"])
2 changes: 1 addition & 1 deletion doc/beacon-metadata.rst
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ For now it distinguishes three different types of links:
Use cases of such information include:

- Mitigating security concerns.
- Allowing users to select paths that e.g. avoid the open internet.
- Allowing users to select paths that e.g. avoid the open Internet.

Internal Hops
-------------
Expand Down
253 changes: 0 additions & 253 deletions doc/build/setup.rst

This file was deleted.

51 changes: 38 additions & 13 deletions doc/conf.py
Original file line number Diff line number Diff line change
@@ -1,20 +1,9 @@
# Configuration file for the Sphinx documentation builder.
#
# This file only contains a selection of the most common options. For a full
# list see the documentation:
# See documentation:
# https://www.sphinx-doc.org/en/master/usage/configuration.html

# -- Path setup --------------------------------------------------------------

# 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.
#
# import os
# import sys
# sys.path.insert(0, os.path.abspath('.'))

import sphinx_rtd_theme # noqa
import subprocess

# -- Project information -----------------------------------------------------

Expand All @@ -31,6 +20,7 @@
extensions = [
'recommonmark',
'sphinx_rtd_theme',
'sphinx.ext.extlinks',
]

# Add any paths that contain templates here, relative to this directory.
Expand All @@ -43,18 +33,53 @@
'venv', 'requirements.in', 'requirements.txt',
'_build', 'Thumbs.db', '.DS_Store',
'manuals/*/*', # manuals/<x>.rst uses "include" directive to compose files from subdirectories
'dev/design/TEMPLATE.rst',
]

master_doc = 'index'

nitpicky = True

option_emphasise_placeholders = True

# -- extlinks definitions for links to github ---

# Determine current git commit for permalinks to files on github.
# Note: somewhat obviously, these links will only work if the current rev has been pushed.
try:
file_ref_commit = subprocess.run(
['git', 'rev-parse', "HEAD"],
capture_output=True, text=True, check=True
).stdout.strip()
except subprocess.CalledProcessError:
file_ref_commit = "master" # only used on unexpected problem with executing git

extlinks = {
# :issue:`123` is an issue link displayed as "#123"
'issue': ('https://github.com/scionproto/scion/issues/%s', '#%s'),
# :file-ref:`foo/bar.go` is a link to a file in the repo, displayed as "foo/bar.go"
'file-ref': ('https://github.com/scionproto/scion/blob/'+file_ref_commit+'/%s', '%s'),
}

# -- Options for HTML output -------------------------------------------------

# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
html_theme = 'sphinx_rtd_theme'

html_theme_options = dict(
style_external_links=True,
)

manpages_url = "https://manpages.debian.org/{path}"


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

html_css_files = [
'css/custom.css',
]
9 changes: 0 additions & 9 deletions doc/contribute/bazel-style.rst

This file was deleted.

8 changes: 0 additions & 8 deletions doc/contribute/json-style.rst

This file was deleted.

1 change: 0 additions & 1 deletion doc/contribute/metrics_test

This file was deleted.

8 changes: 0 additions & 8 deletions doc/contribute/python-style.rst

This file was deleted.

9 changes: 0 additions & 9 deletions doc/contribute/toml-style.rst

This file was deleted.

1 change: 0 additions & 1 deletion doc/contribute/wrappers_test

This file was deleted.

Loading