Skip to content

feat: clean up & refactor majorly #2

feat: clean up & refactor majorly

feat: clean up & refactor majorly #2

Workflow file for this run

name: Code Quality
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Install poetry
run: pipx install poetry
- name: Set up Python
uses: actions/setup-python@v5
id: cq
with:
python-version: '3.11'
cache: 'poetry'
# Install lint deps only
- name: Install dependencies
if: steps.cq.outputs.cache-hit != 'true'
run: poetry install --only=lint --no-interaction --no-root
- name: Check code quality
run: poetry run ruff check .
format:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Install poetry
run: pipx install poetry
- name: Set up Python
uses: actions/setup-python@v5
id: cq
with:
python-version: '3.11'
cache: 'poetry'
# Install lint deps only
- name: Install dependencies
if: steps.cq.outputs.cache-hit != 'true'
run: poetry install --only=lint --no-interaction --no-root
- name: Check code style
run: poetry run ruff format --check
type-check:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Install poetry
run: pipx install poetry
- name: Set up python
id: cq
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'poetry'
# Install only type check dependency
- name: Install dependencies
if: steps.cq.outputs.cache-hit != 'true'
run: poetry install --only=lint --no-root
- name: Check types
run: poetry run mypy tesk/
spell-check:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Install poetry
run: pipx install poetry
- name: Set up Python
uses: actions/setup-python@v5
id: cq
with:
python-version: '3.11'
cache: 'poetry'
# Install lint deps only
- name: Install dependencies
if: steps.cq.outputs.cache-hit != 'true'
run: poetry install --only=lint --no-interaction --no-root
- name: Spell Check
run: poetry run typos