Skip to content

Commit 09206b6

Browse files
committed
Fixed docs, to build pdf and epub formats.
1 parent 1840bc0 commit 09206b6

File tree

2 files changed

+45
-6
lines changed

2 files changed

+45
-6
lines changed

.readthedocs.yaml

Lines changed: 37 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,44 @@ build:
2222
# # See https://github.com/readthedocs/readthedocs.org/pull/11152/
2323
# - POETRY=/home/docs/.local/bin/poetry VIRTUAL_ENV=$READTHEDOCS_VIRTUALENV_PATH make install-packages
2424
## - VIRTUAL_ENV=$READTHEDOCS_VIRTUALENV_PATH poetry install --extras "crypto" --with docs
25-
commands:
25+
26+
# commands:
27+
# - POETRY=/home/docs/.local/bin/poetry make install-poetry
28+
# - POETRY=/home/docs/.local/bin/poetry make install
29+
# - POETRY=/home/docs/.local/bin/poetry make docs
30+
# - ls -l ./docs/_build/html/*
31+
# - mkdir --parents $READTHEDOCS_OUTPUT/html/
32+
# - cp --recursive ./docs/_build/html/* $READTHEDOCS_OUTPUT/html/
33+
34+
jobs:
35+
install:
2636
- POETRY=/home/docs/.local/bin/poetry make install-poetry
2737
- POETRY=/home/docs/.local/bin/poetry make install
28-
- POETRY=/home/docs/.local/bin/poetry make docs
29-
- ls -l ./docs/_build/html/*
30-
- mkdir --parents $READTHEDOCS_OUTPUT/html/
31-
- cp --recursive ./docs/_build/html/* $READTHEDOCS_OUTPUT/html/
38+
build:
39+
html:
40+
- echo "Override default build command for html format"
41+
- POETRY=/home/docs/.local/bin/poetry make docs
42+
- ls -l ./docs/_build/html/*
43+
- mkdir --parents $READTHEDOCS_OUTPUT/html/
44+
- cp --recursive ./docs/_build/html/* $READTHEDOCS_OUTPUT/html/
45+
epub:
46+
- echo "Override default build command for epub format"
47+
- POETRY=/home/docs/.local/bin/poetry make docs-epub
48+
- ls -l ./docs/_build/epub/*
49+
- mkdir -p $READTHEDOCS_OUTPUT/epub/
50+
- cp ./docs/_build/epub/eventsourcing.epub $READTHEDOCS_OUTPUT/epub/
51+
pdf:
52+
- echo "Override default build command for pdf format"
53+
- POETRY=/home/docs/.local/bin/poetry make docs-pdf
54+
- ls -l ./docs/_build/latex/*
55+
- mkdir -p $READTHEDOCS_OUTPUT/pdf/
56+
- cp ./docs/_build/latex/eventsourcing.pdf $READTHEDOCS_OUTPUT/pdf/
57+
# htmlzip:
58+
# - echo "Override default build command for htmlzip format"
59+
# - mkdir -p $READTHEDOCS_OUTPUT/htmlzip/
60+
61+
62+
3263
# jobs:
3364
# pre_create_environment:
3465
# # Select Python version (keep in sync with other versions):
@@ -56,7 +87,7 @@ sphinx:
5687
# fail_on_warning: true
5788

5889
# Optionally build your docs in additional formats such as PDF and ePub
59-
# formats:
90+
formats:
6091
- pdf
6192
- epub
6293

Makefile

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,14 @@ docker-logs:
173173
docs:
174174
cd docs && make html
175175

176+
.PHONY: docs-epub
177+
docs-epub:
178+
cd docs && make epub
179+
180+
.PHONY: docs-pdf
181+
docs-pdf:
182+
cd docs && make latexpdf
183+
176184
#
177185
# .PHONY: brew-services-start
178186
# brew-services-start:

0 commit comments

Comments
 (0)