Skip to content

Commit

Permalink
Use ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
yuanx749 committed Oct 17, 2024
1 parent 60dcbc4 commit 49de9f5
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 16 deletions.
16 changes: 5 additions & 11 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,9 @@ repos:
- id: end-of-file-fixer
- id: trailing-whitespace
args: [--markdown-linebreak-ext=md]
- repo: https://github.com/psf/black
rev: 23.3.0
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.6.9
hooks:
- id: black
- repo: https://github.com/PyCQA/isort
rev: 5.12.0
hooks:
- id: isort
- repo: https://github.com/PyCQA/flake8
rev: 6.0.0
hooks:
- id: flake8
- id: ruff
args: [--fix, --show-fixes]
- id: ruff-format
2 changes: 1 addition & 1 deletion pycdhit/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from ._commands import * # noqa: F403
from ._io import * # noqa: F403

VERSION = "1.1.2"
VERSION = "1.1.3"

__all__ = [ # noqa: F405
"CommandBase",
Expand Down
10 changes: 6 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,7 @@ dynamic = ["version"]
[project.optional-dependencies]
dev = [
"pre-commit==3.3.2",
"black==23.3.0",
"flake8==6.0.0",
"isort==5.12.0",
"ruff==0.6.9",
"pytest>=7.0.0",
"pytest-cov>=4.0.0",
"notebook>=6.5.4",
Expand All @@ -47,5 +45,9 @@ packages = ["pycdhit"]
[tool.setuptools.dynamic]
version = {attr = "pycdhit.VERSION"}

[tool.black]
[tool.ruff]
line-length = 79
extend-exclude = ["*.ipynb"]

[tool.ruff.lint]
select = ["E4", "E7", "E9", "F", "I"]

0 comments on commit 49de9f5

Please sign in to comment.