31 lines
616 B
YAML
31 lines
616 B
YAML
|
# pre-commit workflow
|
||
|
#
|
||
|
# Ensures the codebase passes the pre-commit stack.
|
||
|
|
||
|
name: pre-commit ci
|
||
|
|
||
|
on: [push]
|
||
|
|
||
|
jobs:
|
||
|
python_ci:
|
||
|
runs-on: ubuntu-latest
|
||
|
steps:
|
||
|
- uses: actions/checkout@v3
|
||
|
|
||
|
- name: Install UV
|
||
|
run: python -m pip install uv
|
||
|
|
||
|
- name: Create virtual environment
|
||
|
run: uv venv
|
||
|
|
||
|
- name: Activate virtual environment
|
||
|
run: |
|
||
|
. .venv/bin/activate
|
||
|
echo PATH=$PATH >> $GITHUB_ENV
|
||
|
|
||
|
- name: Install dependencies
|
||
|
run: uv pip install -r requirements.txt
|
||
|
|
||
|
- name: Run pre-commit hooks
|
||
|
run: pre-commit run --all-files --show-diff-on-failure
|