Skip to content

improve doc

improve doc #31

Workflow file for this run

name: test
permissions:
contents: read
on:
- pull_request
- push
jobs:
python-test:
runs-on: ubuntu-latest
defaults:
run:
working-directory: python
strategy:
matrix:
version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v4
- name: Install poetry
run: curl -sSL https://install.python-poetry.org | python3 -
env:
POETRY_VERSION: 1.7.0
- name: Add Poetry to path
run: echo "${HOME}/.poetry/bin" >> $GITHUB_PATH
- name: Set up Python ${{ matrix.version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.version }}
cache: "poetry"
- name: Install Poetry Packages
run: |
poetry env use ${{ matrix.version }}
poetry install
- name: Add venv to path
run: echo `poetry env info --path`/bin/ >> $GITHUB_PATH
- run: ruff check --output-format github .
- run: ruff format --check .
- run: mypy --check-untyped-defs .
- run: pyright --warnings .
- run: pytest -s --cov=dyna_store --cov-report=html
- uses: actions/upload-artifact@v4
with:
name: code-coverage-${{ matrix.version }}
path: htmlcov/
- name: Upload coverage to codecov
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
js-test:
runs-on: ubuntu-latest
defaults:
run:
working-directory: javascript
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v1
- run: bun install
- run: bun test --coverage
release:
needs: python-test
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
runs-on: ubuntu-latest
defaults:
run:
working-directory: frontend
environment:
name: release
url: https://pypi.org/p/dyna-store
permissions:
id-token: write
steps:
- uses: actions/checkout@v4
- name: Install poetry
run: curl -sSL https://install.python-poetry.org | python3 -
env:
POETRY_VERSION: 1.7.0
- name: Add Poetry to path
run: echo "${HOME}/.poetry/bin" >> $GITHUB_PATH
- name: Set up Python 3.11
uses: actions/setup-python@v5
with:
python-version: "3.11"
cache: "poetry"
- name: Install Poetry Packages
run: |
poetry env use "3.11"
poetry install --only dev
- run: echo `poetry env info --path`/bin/ >> $GITHUB_PATH
- run: poetry build
- uses: pypa/gh-action-pypi-publish@release/v1