Skip to content

Commit

Permalink
Merge branch 'master' into fix-fk-null-update
Browse files Browse the repository at this point in the history
  • Loading branch information
collerek authored Feb 12, 2024
2 parents fe84316 + 3a206dd commit 57ab550
Show file tree
Hide file tree
Showing 6 changed files with 368 additions and 86 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/benchmark.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: codspeed-benchmarks

on:
push:
branches: [ master, pydantic_v2 ]
pull_request:
branches: [ master, pydantic_v2 ]
# `workflow_dispatch` allows CodSpeed to trigger backtest
# performance analysis in order to generate initial data.
workflow_dispatch:

jobs:
benchmarks:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
with:
python-version: "3.11"

- name: Install Poetry
uses: snok/[email protected]
with:
version: 1.4.2
virtualenvs-create: false

- name: Poetry details
run: |
poetry --version
poetry config --list
- name: Install dependencies
run: poetry install --extras "all"

- name: Run benchmarks
uses: CodSpeedHQ/action@v2
with:
token: ${{ secrets.CODSPEED_TOKEN }}
run: poetry run pytest benchmarks/ --codspeed
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
2 changes: 1 addition & 1 deletion .github/workflows/test-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ jobs:
run: bash scripts/test.sh
- run: mypy ormar tests benchmarks
- name: Upload coverage
uses: codecov/[email protected].4
uses: codecov/[email protected].6
- name: Test & publish code coverage
uses: paambaati/[email protected]
if: github.event.pull_request.head.repo.full_name == 'collerek/ormar'
Expand Down
7 changes: 7 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 All @@ -97,6 +102,8 @@ extra:
analytics:
provider: google
property: UA-72514911-3
version:
provider: mike
extra_javascript:
- https://cdnjs.cloudflare.com/ajax/libs/highlight.js/10.1.1/highlight.min.js
- javascripts/config.js
Expand Down
Loading

0 comments on commit 57ab550

Please sign in to comment.