Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 39 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: CI

on:
push:
branches: [main, develop]
pull_request:
branches: [main]

jobs:
quality:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12"]

steps:
- uses: actions/checkout@v4

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e ".[dev]"

- name: Lint with ruff
run: ruff check src/ tests/

- name: Check formatting with ruff
run: ruff format --check src/ tests/

- name: Type check with mypy
run: mypy src/ tests/

- name: Test with pytest
run: pytest --cov=src --cov-report=term-missing
40 changes: 0 additions & 40 deletions .github/workflows/python-package.yml

This file was deleted.

9 changes: 8 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,16 @@ __pycache__/
dist/
build/
*.spec
.pytest_cache/
.mypy_cache/
.ruff_cache/

# Virtual environment
.venv/

# User data (local, not tracked)
data/times.json
data/.welcome_shown

# IDE
.vscode/
Expand All @@ -18,4 +25,4 @@ data/times.json
.DS_Store
Thumbs.db

3x3_times.json.bak
3x3_times.json.bak
25 changes: 25 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.5.0
hooks:
- id: ruff
args: [--fix]
- id: ruff-format

- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.10.0
hooks:
- id: mypy
args: [--config-file=pyproject.toml]
additional_dependencies: [customtkinter>=5.2.2]

- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.6.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- id: check-toml
- id: check-added-large-files
- id: check-merge-conflict
- id: detect-private-key
Loading
Loading