Skip to content

Deploy docs without a seperate GitHub action package. #150

Deploy docs without a seperate GitHub action package.

Deploy docs without a seperate GitHub action package. #150

Workflow file for this run

name: Test
on:
- push
- pull_request
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
cache: "pip"
- name: Ensure latest pip
run: python -m pip install --upgrade pip
- name: Install hatch
run: python -m pip install hatch
- name: Configure hatch
run: hatch config set "dirs.env.virtual" ".venv"
- name: Restore cache hatch virtual environments
id: cache-venvs-restore
uses: actions/cache/restore@v3
with:
path: .venv
key: python-${{ matrix.python-version }}-venvs-${{ hashFiles('pyproject.toml') }}
- name: Run lint
run: hatch run lint:all
- name: Run tests
run: hatch run +py=${{ matrix.python-version }} test:test
- name: Save cache hatch virtual environments
id: cache-venvs-save
uses: actions/cache/save@v3
with:
path: .venv
key: ${{ steps.cache-venvs-restore.outputs.cache-primary-key }}