From 4174dbed0c47efc2a361e24c5c001b57cf2d7e4c Mon Sep 17 00:00:00 2001 From: Guido Grazioli Date: Thu, 10 Aug 2023 16:36:20 +0200 Subject: [PATCH] use antsibul sphinx ext, ansible pygments Signed-off-by: Guido Grazioli --- .github/workflows/docs.yml | 4 ++-- docs/conf.py | 3 ++- docs/requirements.txt | 1 + 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index a3a5abd..517e2c7 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -26,7 +26,7 @@ jobs: pages: write steps: - name: Check out code - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: path: ansible_collections/kubevirt/core fetch-depth: 0 @@ -34,7 +34,7 @@ jobs: - name: Set up Python uses: actions/setup-python@v4 with: - python-version: 3.9 + python-version: 3.11 cache: 'pip' - name: Install doc dependencies diff --git a/docs/conf.py b/docs/conf.py index 1faf986..8b8d7dc 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -43,6 +43,7 @@ extensions = [ 'myst_parser', 'sphinx.ext.autodoc', 'sphinx.ext.intersphinx', + 'sphinx_antsibull_ext', 'ansible_basic_sphinx_ext', ] @@ -71,7 +72,7 @@ language = None exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store', '.tmp'] # The name of the Pygments (syntax highlighting) style to use. -pygments_style = 'sphinx' +pygments_style = 'ansible' highlight_language = 'YAML+Jinja' diff --git a/docs/requirements.txt b/docs/requirements.txt index c43be53..c8f8e2d 100644 --- a/docs/requirements.txt +++ b/docs/requirements.txt @@ -2,6 +2,7 @@ antsibull>=0.17.0 antsibull-docs antsibull-changelog ansible-core>=2.14.1 +ansible-pygments sphinx-rtd-theme git+https://github.com/felixfontein/ansible-basic-sphinx-ext myst-parser