diff --git a/.github/workflows/code-check.yml b/.github/workflows/code-check.yml index bdfcc46..d9e2f04 100644 --- a/.github/workflows/code-check.yml +++ b/.github/workflows/code-check.yml @@ -10,31 +10,13 @@ on: - "!gh-pages" jobs: - python-format-black: - name: Python format [black] - runs-on: ubuntu-latest - steps: - - name: Checkout the code - uses: actions/checkout@v3 - - - name: Set up Python - uses: actions/setup-python@v4 - with: - python-version: "3.10" - - - name: Install black - run: | - pip install black>=23 - - - name: Format - run: black --check . python-lint-ruff: name: Python lint [ruff] runs-on: ubuntu-latest steps: - name: Checkout the code - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Set up Python uses: actions/setup-python@v4 @@ -46,4 +28,7 @@ jobs: pip install ruff - name: Lint - run: ruff . + run: ruff check . + + - name: Format + run: ruff format . --check \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index a5f304b..0eb350b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -84,14 +84,13 @@ omit = ["splito/__init__.py"] output = "coverage.xml" [tool.ruff] -ignore = [ +lint.ignore = [ "E501", # Never enforce `E501` (line length violations). ] line-length = 110 -target-version = "py311" +target-version = "py310" -[tool.ruff.per-file-ignores] -"__init__.py" = [ +lint.per-file-ignores."__init__.py" = [ "F401", # imported but unused "E402", # Module level import not at top of file -] +] \ No newline at end of file