Skip to content

Commit

Permalink
support sphinx-build -j<N> (parallel build)
Browse files Browse the repository at this point in the history
  • Loading branch information
bluetech authored and davidism committed Apr 29, 2024
1 parent 563cce1 commit 0e9c08c
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ Version 2.1.3

Unreleased

- Allow Sphinx's parallel build feature. :issue:`88`

Version 2.1.2
-------------
Expand Down
5 changes: 5 additions & 0 deletions src/pallets_sphinx_themes/themes/click/domain.py
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,11 @@ class ClickDomain(Domain):
label = "Click"
directives = {"example": DeclareExampleDirective, "run": RunExampleDirective}

def merge_domaindata(self, docnames, otherdata):
# Needed to support parallel build.
# Not using self.data -- nothing to merge.
pass


def delete_example_runner_state(app, doctree):
"""Close and remove the :class:`ExampleRunner` instance once the
Expand Down
5 changes: 5 additions & 0 deletions src/pallets_sphinx_themes/themes/jinja/domain.py
Original file line number Diff line number Diff line change
Expand Up @@ -258,6 +258,11 @@ class JinjaDomain(Domain):
"nodes": NodesDirective,
}

def merge_domaindata(self, docnames, otherdata):
# Needed to support parallel build.
# Not using self.data -- nothing to merge.
pass


def setup(app):
app.add_domain(JinjaDomain)

0 comments on commit 0e9c08c

Please sign in to comment.