Skip to content

Commit 1275b7a

Browse files
committed
Replace black, isort and flake8 with ruff
1 parent b11ee46 commit 1275b7a

4 files changed

Lines changed: 7 additions & 25 deletions

File tree

.flake8

Lines changed: 0 additions & 2 deletions
This file was deleted.

.github/workflows/on-commit.yml

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -36,16 +36,7 @@ jobs:
3636

3737
steps:
3838
- uses: actions/checkout@v3
39-
- name: Set up Python 3.13
40-
uses: actions/setup-python@v4
41-
with:
42-
python-version: '3.13'
43-
cache: 'pip'
44-
cache-dependency-path: 'requirements/style.txt'
45-
- name: Install dependencies
46-
run: python -m pip install -r requirements/style.txt
47-
- name: Run style checks
48-
run: |
49-
python -m flake8 .
50-
python -m isort --check --diff .
51-
python -m black --check --diff .
39+
- name: Install ruff and apply 'ruff check'
40+
uses: astral-sh/ruff-action@v3
41+
- name: Check for formatting changes
42+
run: ruff format --check --diff

pyproject.toml

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,11 @@ dynamic = ['version']
2020
[project.urls]
2121
source = 'https://github.com/mdickinson/simplefractions'
2222

23-
[tool.black]
24-
target-version = ['py38']
25-
26-
[tool.isort]
27-
profile = 'black'
28-
order_by_type = 'False'
29-
3023
[tool.mypy]
3124
strict = true
3225

26+
[tool.ruff.lint]
27+
extend-select = ["I"]
28+
3329
[tool.setuptools_scm]
3430
version_scheme = 'release-branch-semver'

requirements/style.txt

Lines changed: 0 additions & 3 deletions
This file was deleted.

0 commit comments

Comments
 (0)