feat: add CI

This commit is contained in:
Dmitry Belan
2026-07-14 12:50:58 +03:00
parent dac96f74c8
commit 002a264f1d
2 changed files with 254 additions and 0 deletions
+34
View File
@@ -0,0 +1,34 @@
name: CI Check
on: [push, pull_request]
jobs:
lint-and-check:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
# Важно для commitizen, чтобы подтянуть историю всех коммитов
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install dependencies
run: |
pip install ruff commitizen
- name: Run Ruff Check
# Ruff автоматически подхватит настройки из pyproject.toml
run: ruff check .
- name: Run Ruff Format Check
# Проверка соответствия стилю
run: ruff format --check .
- name: Check Commit Convention
# Проверка всех новых коммитов в PR или последней пуш-сессии
run: cz check --rev-range origin/main..HEAD