Skip to content

Add Ruff linting CI and reformat #1

Add Ruff linting CI and reformat

Add Ruff linting CI and reformat #1

Workflow file for this run

name: ci-restart
on:
# Triggers the workflow on pushes to the "main" branch, i.e., PR merges
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
workflow_dispatch:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with: { python-version: '3.10' }
- run: python -m pip install --upgrade pip && python -m pip install ruff
- run: ruff format --diff .
- run: ruff check --diff .
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with: { python-version: '3.10' }
- run: |
python -m pip install --upgrade pip
python -m venv venv
. venv/bin/activate
pip install .[dev]
# tests are currently empty
pytest || [ $? -eq 5 ]