Skip to content

Merge pull request #63 from 4Freye/dev_uv #92

Merge pull request #63 from 4Freye/dev_uv

Merge pull request #63 from 4Freye/dev_uv #92

Workflow file for this run

name: CI
permissions:
contents: write
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.9'
- name: Install dependencies
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh # install uv
uv sync
- name: Run tests
run: uv run pytest
docs:
# Only run this job on push to main (includes merges) and if tests pass
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
needs: test # Only build docs if tests pass
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.9'
- name: Generate API documentation with pdoc
run: |
rm -rf docs # Remove old docs directory if it exists
pdoc panelsplit -o docs -d numpy --no-include-undocumented
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs