Skip to content
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
31 changes: 31 additions & 0 deletions .github/workflows/docs-pages.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: "Docs / Publish"

on:
push:
branches:
- main
paths:
- "docs/**"
workflow_dispatch:

jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
persist-credentials: false
fetch-depth: 0
- name: Set up Python
uses: actions/[email protected]
with:
python-version: 3.7
- name: Set up Poetry
run: curl -sSL https://install.python-poetry.org | python -
- name: Build docs
run: make -C docs multiversion
- name: Deploy docs to GitHub Pages
run: ./docs/_utils/deploy.sh
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
29 changes: 0 additions & 29 deletions .github/workflows/[email protected]

This file was deleted.

26 changes: 26 additions & 0 deletions .github/workflows/docs-pr.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: "Docs / Build PR"

on:
pull_request:
branches:
- main
paths:
- "docs/**"

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
persist-credentials: false
fetch-depth: 0
- name: Set up Python
uses: actions/[email protected]
with:
python-version: 3.7
- name: Set up Poetry
run: curl -sSL https://install.python-poetry.org | python -
- name: Build docs
run: make -C docs test
25 changes: 0 additions & 25 deletions .github/workflows/[email protected]

This file was deleted.

8 changes: 4 additions & 4 deletions docs/Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# You can set these variables from the command line.
POETRY = $(HOME)/.poetry/bin/poetry
POETRY = $(HOME)/.local/bin/poetry
SPHINXOPTS =
SPHINXBUILD = $(POETRY) run sphinx-build
PAPER =
Expand All @@ -24,7 +24,8 @@ pristine: clean

.PHONY: setup
setup:
./_utils/setup.sh
$(POETRY) install
$(POETRY) update

.PHONY: clean
clean:
Expand Down Expand Up @@ -70,14 +71,13 @@ linkcheck: setup

.PHONY: multiversion
multiversion: setup
@mkdir -p $(HOME)/.cache/pypoetry/virtualenvs
$(POETRY) run sphinx-multiversion source _build/dirhtml
@echo
@echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml."

.PHONY: multiversionpreview
multiversionpreview: multiversion
$(POETRY) run python3 -m http.server 5500 --directory $(BUILDDIR)/dirhtml
$(POETRY) run python -m http.server 5500 --directory $(BUILDDIR)/dirhtml

.PHONY: test
test: setup
Expand Down
23 changes: 0 additions & 23 deletions docs/_utils/pyproject_template.toml

This file was deleted.

12 changes: 0 additions & 12 deletions docs/_utils/setup.sh

This file was deleted.

17 changes: 7 additions & 10 deletions docs/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,14 @@ authors = ["ScyllaDB Documentation Contributors"]

[tool.poetry.dependencies]
python = "^3.7"
pyyaml = "5.3"
pygments = "2.8.0"
recommonmark = "0.5.0"
sphinx-scylladb-theme = "~1.0.0"
pyyaml = "^6.0"
pygments = "2.11.2"
recommonmark = "^0.7.1"
sphinx-scylladb-theme = "~1.1.0"
sphinx-sitemap = "2.1.0"
sphinx-autobuild = "0.7.1"
Sphinx = "2.4.4"
sphinx-multiversion-scylla = "~0.2.6"

[tool.poetry.dev-dependencies]
pytest = "5.2"
sphinx-autobuild = "^2021.3.14"
Sphinx = "^4.3.2"
sphinx-multiversion-scylla = "~0.2.10"

[build-system]
requires = ["poetry>=0.12"]
Expand Down
6 changes: 2 additions & 4 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

import recommonmark
from recommonmark.transform import AutoStructify
from pygments.lexers.configs import TOMLLexer
from pygments.lexers.rust import RustLexer
from sphinx.highlighting import lexers

Expand Down Expand Up @@ -49,9 +50,6 @@
# The name of the Pygments (syntax highlighting) style to use.
pygments_style = 'sphinx'

# If true, `todo` and `todoList` produce output, else they produce nothing.
todo_include_todos = True

# Setup Sphinx
def setup(sphinx):
sphinx.add_config_value('recommonmark_config', {
Expand All @@ -60,6 +58,7 @@ def setup(sphinx):
}, True)
sphinx.add_transform(AutoStructify)
lexers['rust'] = RustLexer()
lexers['toml'] = TOMLLexer()


# -- Options for not found extension -------------------------------------------
Expand Down Expand Up @@ -110,7 +109,6 @@ def setup(sphinx):
'default_branch': 'main',
'github_repository': 'scylladb/scylla-rust-driver',
'github_issues_repository': 'scylladb/scylla-rust-driver',
'hide_sidebar_index': 'false',
'hide_banner': 'true',
'site_description': 'Scylla Driver for Rust.',
'hide_edit_this_page_button': 'false'
Expand Down