Skip to content

Commit

Permalink
Add mike (#1264)
Browse files Browse the repository at this point in the history
* check return types

* set site url

* change docs publish to tag, for now comment it out
  • Loading branch information
collerek authored Feb 12, 2024
1 parent 3643239 commit 7f3b158
Show file tree
Hide file tree
Showing 4 changed files with 92 additions and 4 deletions.
14 changes: 11 additions & 3 deletions .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
name: Build Documentation using MkDocs
on:
push:
branches: [ master ]
# Pattern matched against refs/tags
tags:
- '**'
jobs:
build:
name: Build and Deploy Documentation
Expand All @@ -19,6 +21,12 @@ jobs:
poetry install --extras "all"
env:
POETRY_VIRTUALENVS_CREATE: false
- name: Deploy
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
- name: Test
run: |
mkdocs gh-deploy --force
echo $RELEASE_VERSION
echo ${{ env.RELEASE_VERSION }}
# - name: Deploy
# run: |
# mike deploy --push --update-aliases ${{ env.RELEASE_VERSION }} latest
5 changes: 5 additions & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
site_name: ormar
site_url: 'https://collerek.github.io/ormar/'
site_description: A simple async ORM with fastapi in mind and pydantic validation.
nav:
- Overview: index.md
Expand Down Expand Up @@ -77,6 +78,10 @@ markdown_extensions:
- pymdownx.highlight:
linenums: true
plugins:
- mike:
alias_type: symlink
canonical_version: latest
version_selector: true
- search
- gen-files:
scripts:
Expand Down
76 changes: 75 additions & 1 deletion poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ all = [
httpx = "^0.24.1"
asgi-lifespan = "^2.1.0"
pytest-codspeed = "^2.2.0"
mike = "^2.0.0"

[build-system]
requires = ["poetry-core>=1.0.0"]
Expand Down

0 comments on commit 7f3b158

Please sign in to comment.