Skip to content

Commit

Permalink
Work around missing myst-parser on Bullseye
Browse files Browse the repository at this point in the history
Bullseye (and by extension, Byzantium) doesn’t provide the
`python3-myst-parser` package.
As a workaround, invoke `pandoc` directly in `override_dh_auto_build`.

Also remove the doc generating step from the GitHub workflow.
It’s not strictly needed on Debian packaging branches. It also
wouldn’t work anyway without installing Pandoc and generating the
.rst file first.
  • Loading branch information
claui committed Jul 18, 2024
1 parent 160a9c2 commit cb18a47
Show file tree
Hide file tree
Showing 5 changed files with 50 additions and 0 deletions.
1 change: 1 addition & 0 deletions debian/changelog
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
itchcraft (0.1.0~bpo11+1) UNRELEASED; urgency=medium

* Work around missing Poetry package on Bullseye
* Work around missing `myst-parser` on Bullseye

-- Claudia Pellegrino <[email protected]> Thu, 18 Jul 2024 19:55:40 +0200

Expand Down
1 change: 1 addition & 0 deletions debian/clean
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
debian/USAGE.rst
46 changes: 46 additions & 0 deletions debian/patches/replace-myst-parser.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 86f39a6..ac9f72c 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -57,6 +57,3 @@ jobs:

- name: Run linter
run: poetry run poe linter
-
- - name: Run man page generator
- run: poetry run poe doc
diff --git a/.gitignore b/.gitignore
index af67b02..d1d04ac 100644
--- a/.gitignore
+++ b/.gitignore
@@ -5,6 +5,7 @@
/debian/itchcraft/
/debian/itchcraft.*.debhelper
/debian/itchcraft.substvars
+/debian/*.rst
/dist/
/.pc/
/.venv/
diff --git a/doc/sphinx/conf.py b/doc/sphinx/conf.py
index a91740a..b3f6a84 100644
--- a/doc/sphinx/conf.py
+++ b/doc/sphinx/conf.py
@@ -14,7 +14,6 @@ description = 'Alternative frontend for heat-based USB insect bite healers'
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration

extensions = [
- 'myst_parser',
'sphinx.ext.autodoc',
'sphinx.ext.napoleon',
]
diff --git a/doc/sphinx/index.rst b/doc/sphinx/index.rst
index dad1edc..6077374 100644
--- a/doc/sphinx/index.rst
+++ b/doc/sphinx/index.rst
@@ -5,5 +5,4 @@ Welcome to Itchcraft's documentation!
:maxdepth: 2
:caption: Contents:

-.. include:: ../../USAGE.md
- :parser: myst_parser.sphinx_
+.. include:: ../../debian/USAGE.rst
1 change: 1 addition & 0 deletions debian/patches/series
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
replace-poetry.patch
replace-myst-parser.patch
1 change: 1 addition & 0 deletions debian/rules
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@ export PYBUILD_NAME=itchcraft

override_dh_auto_build:
dh_auto_build
pandoc -o debian/USAGE.rst --shift-heading-level-by=1 USAGE.md
PYTHONPATH=. python3 -m sphinx -NW -b man doc/sphinx build/man

0 comments on commit cb18a47

Please sign in to comment.