-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: burgholzer <[email protected]>
- Loading branch information
1 parent
26a7401
commit 9b62114
Showing
4 changed files
with
1,146 additions
and
575 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,39 @@ | ||
version: 2 | ||
|
||
submodules: | ||
include: all | ||
recursive: true | ||
formats: | ||
- htmlzip | ||
|
||
build: | ||
os: ubuntu-22.04 | ||
tools: | ||
python: "3.11" | ||
jobs: | ||
post_checkout: | ||
# Skip docs build if the commit message contains "skip ci" | ||
- (git --no-pager log --pretty="tformat:%s -- %b" -1 | grep -viq "skip ci") || exit 183 | ||
# Skip docs build if there are no changes related to docs | ||
- | | ||
if [ "$READTHEDOCS_VERSION_TYPE" = "external" ] && git diff --quiet origin/main -- docs/ .readthedocs.yaml src/mqt/ src/python include/python .github/contributing* .github/workflows/support*; | ||
then | ||
exit 183; | ||
fi | ||
# Unshallow the git clone and fetch tags to get proper version information | ||
- git fetch --unshallow --tags | ||
python: "3.12" | ||
commands: | ||
# Skip docs build if the commit message contains "skip ci" | ||
- (git --no-pager log --pretty="tformat:%s -- %b" -1 | grep -viq "skip ci") || exit 183 | ||
# Skip docs build if there are no changes related to docs | ||
- | | ||
if [ "$READTHEDOCS_VERSION_TYPE" = "external" ] && git diff --quiet origin/main -- docs/ .readthedocs.yaml src/mqt/ src/python include/*/python .github/contributing* .github/support*; | ||
then | ||
exit 183; | ||
fi | ||
# Set up uv and a virtual environment | ||
- asdf plugin add uv | ||
- asdf install uv latest | ||
- asdf global uv latest | ||
# Unshallow the git clone and fetch tags to get proper version information | ||
- git fetch --unshallow --tags | ||
# Run the html builder | ||
- uv run --frozen --no-dev --group docs -m sphinx -T -b html -d docs/_build/doctrees -D language=en docs/source $READTHEDOCS_OUTPUT/html | ||
# Run the htmlzip builder and create a zip file | ||
- uv run --frozen --no-dev --group docs -m sphinx -T -b dirhtml -d docs/_build/doctrees -D language=en docs/source docs/_build/dirhtml | ||
- mkdir -p $READTHEDOCS_OUTPUT/htmlzip | ||
- zip -r $READTHEDOCS_OUTPUT/htmlzip/html.zip docs/_build/dirhtml/* | ||
# Run the latex builder and create a pdf file | ||
- uv run --frozen --no-dev --group docs -m sphinx -T -b latex -d docs/_build/doctrees -D language=en docs/source docs/_build/latex | ||
- cd docs/_build/latex && latexmk -pdf -f -dvi- -ps- -interaction=nonstopmode -jobname=$READTHEDOCS_PROJECT | ||
- mkdir -p $READTHEDOCS_OUTPUT/pdf | ||
- cp docs/_build/latex/$READTHEDOCS_PROJECT.pdf $READTHEDOCS_OUTPUT/pdf/$READTHEDOCS_PROJECT.pdf | ||
|
||
sphinx: | ||
configuration: docs/source/conf.py | ||
|
||
python: | ||
install: | ||
- method: pip | ||
path: . | ||
extra_requirements: | ||
- docs | ||
configuration: docs/conf.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.