Skip to content

Commit 860ea16

Browse files
authored
Fix/docs build (#114)
1 parent 73cfde1 commit 860ea16

File tree

4 files changed

+197
-32
lines changed

4 files changed

+197
-32
lines changed

β€Ž.github/workflows/workflow.yamlβ€Ž

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,12 +99,23 @@ jobs:
9999
OLD_VERSION=$(poetry version -s)
100100
python -c "from packaging import version;assert version.parse(\"${NEW_VERSION}\") > version.parse(\"${OLD_VERSION}\"), \"❌ Bad version bump detected: you must bump the version in pyproject.toml\""
101101
python -c "print(\"βœ… Version will be bumped from ${OLD_VERSION} to ${NEW_VERSION}\")"
102+
test-docs-build:
103+
name: Run Test Docs Build
104+
runs-on: ubuntu-latest
105+
steps:
106+
- uses: actions/checkout@v2
107+
- name: Set up Python
108+
uses: actions/setup-python@v2
109+
- name: Install and configure Poetry
110+
uses: snok/install-poetry@v1.3.1
111+
- name: Build Docs
112+
run: make docs-build
102113
docs:
103114
if: github.ref == 'refs/heads/main'
104115
concurrency: docs-branch
105116
name: πŸš€ Deploy Docs πŸ“„
106117
runs-on: ubuntu-latest
107-
needs: ["test", "lint"]
118+
needs: ["test", "lint", "test-docs-build"]
108119
steps:
109120
- uses: actions/checkout@v2
110121
with:
@@ -122,7 +133,7 @@ jobs:
122133
if: github.ref == 'refs/heads/main'
123134
name: πŸš€ PyPi Release πŸ“¦
124135
runs-on: ubuntu-latest
125-
needs: ["test", "lint"]
136+
needs: ["test", "lint", "test-docs-build"]
126137
steps:
127138
- uses: actions/checkout@v2
128139
- name: Set up Python

β€ŽMakefileβ€Ž

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,10 @@ test-mutation: .init
4040
@poetry run python -m pip install mutmut
4141
@(poetry run pytest --cov && poetry run mutmut run --use-coverage && echo "---- βœ… Passed ----" && exit 0 || echo "---- ❌ Failed ----" && exit 1)
4242

43+
docs-build: .init
44+
@echo ---- πŸ—οΈ Building docs ----
45+
@poetry run mkdocs build
46+
4347
docs-serve: .init
4448
@echo ---- πŸ“ Serving docs ----
4549
@poetry run mkdocs serve --dev-addr localhost:8001

0 commit comments

Comments
Β (0)