Skip to content

Commit be29bc8

Browse files
committed
use CommandBuilder
1 parent e26854e commit be29bc8

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

docsrc/poly.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
from sphinx_polyversion.driver import DefaultDriver
66
from sphinx_polyversion.git import Git, GitRef, GitRefType, file_predicate, refs_by_type
77
from sphinx_polyversion.pyvenv import Pip
8-
from sphinx_polyversion.sphinx import SphinxBuilder
8+
from sphinx_polyversion.sphinx import CommandBuilder
99

1010
#: Regex matching the branches to build docs for
1111
BRANCH_REGEX = r"master-doctest"
@@ -19,8 +19,8 @@
1919
#: Source directory
2020
SOURCE_DIR = "docsrc/"
2121

22-
#: Arguments to pass to `poetry install`
23-
POETRY_ARGS = "numpy"
22+
#: Arguments to pass to `pip install`
23+
POETRY_ARGS = "bayesflow"
2424

2525
#: Arguments to pass to `sphinx-build`
2626
SPHINX_ARGS = "-a -v"
@@ -33,7 +33,6 @@
3333
],
3434
"current": GitRef("master-doctest", "", "", GitRefType.TAG, datetime.fromtimestamp(6)),
3535
}
36-
MOCK = True
3736

3837

3938
#: Data passed to templates
@@ -74,11 +73,10 @@ def root_data(driver):
7473
buffer_size=1 * 10**9, # 1 GB
7574
predicate=file_predicate([src]), # exclude refs without source dir
7675
),
77-
builder=SphinxBuilder(src / "source", args=SPHINX_ARGS.split()),
76+
builder=CommandBuilder(source=src / "source", cmd=["make", "github"]),
7877
env=Pip.factory(args=POETRY_ARGS.split(), venv="buildvenv"),
7978
template_dir=root / src / "polyversion/templates",
8079
static_dir=root / src / "polyversion/static",
8180
data_factory=data,
8281
root_data_factory=root_data,
83-
mock=MOCK_DATA,
84-
).run(MOCK)
82+
).run(False)

0 commit comments

Comments
 (0)