Skip to content

Commit

Permalink
ci: Migrate to using uv
Browse files Browse the repository at this point in the history
  • Loading branch information
bwt-sloanj committed Sep 24, 2024
1 parent 2aa1309 commit 4f189a1
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Python application
name: Run Python Tests and Pre-Commit Hooks

on:
push:
Expand All @@ -8,24 +8,26 @@ on:
branches:
- main
jobs:
build:
tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- name: Set up Python 3.10
uses: actions/setup-python@v2
uses: actions/setup-python@v5
with:
python-version: '3.10'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pre-commit
pip install -e .[dev]
- name: Install uv
uses: astral-sh/setup-uv@v3
with:
version: "0.4.15"

- name: Install project
run: uv sync --all-extras --dev

- name: Run pre-commit hooks
run: pre-commit run --all-files
run: uvx --with pre-commit pre-commit run --all-files

- name: Run tests
run: |
Expand Down

0 comments on commit 4f189a1

Please sign in to comment.