forked from webpro/programming-principles
-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (27 loc) · 929 Bytes
/
ci.yml
File metadata and controls
36 lines (27 loc) · 929 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: CI
# This workflow will do a combination of testing, build, and deployment tasks
# For more information see: https://docs.github.com/actions/automating-builds-and-tests/about-continuous-integration
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build_and_test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"
cache: "uv"
cache-dependency-path: "**/pyproject.toml"
- name: Install dependencies with uv
run: "uv pip install --system --quiet --no-cache-dir -e .[dev]"
- name: Lint with Ruff
run: "uv run --quiet --no-cache-dir ruff check ."
- name: Format with Ruff
run: "uv run --quiet --no-cache-dir ruff format ."
- name: Test with Pytest
run: "uv run --quiet --no-cache-dir pytest"