mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-06-23 15:30:45 -04:00
46 lines
1.1 KiB
TOML
46 lines
1.1 KiB
TOML
[project]
|
|
requires-python = ">=3.8"
|
|
|
|
[tool.ruff]
|
|
line-length = 160
|
|
target-version = 'py38'
|
|
builtins = ['_', 'I', 'P']
|
|
include = ['*.py', '*.recipe']
|
|
exclude = [
|
|
"*_ui.py",
|
|
"bypy/*",
|
|
"setup/polib.py",
|
|
"setup/linux-installer.py",
|
|
"src/css_selectors/*",
|
|
"src/polyglot/*",
|
|
"src/templite/*",
|
|
"src/tinycss/*",
|
|
]
|
|
|
|
[tool.ruff.format]
|
|
quote-style = 'single'
|
|
|
|
[tool.ruff.lint]
|
|
ignore = ['E402', 'E722', 'E741']
|
|
select = ['E', 'F', 'I', 'W', 'INT']
|
|
|
|
[tool.ruff.lint.per-file-ignores]
|
|
"src/calibre/ebooks/unihandecode/*codepoints.py" = ['E501', 'W191']
|
|
"src/qt/*.py" = ['I']
|
|
"src/qt/*.pyi" = ['I']
|
|
|
|
[tool.ruff.lint.isort]
|
|
detect-same-package = true
|
|
extra-standard-library = ["aes", "elementmaker", "encodings"]
|
|
known-first-party = ["calibre_extensions", "calibre_plugins", "polyglot"]
|
|
known-third-party = ["odf", "qt", "templite", "tinycss", "css_selectors"]
|
|
relative-imports-order = "closest-to-furthest"
|
|
split-on-trailing-comma = false
|
|
section-order = ['__python__', "future", "standard-library", "third-party", "first-party", "local-folder"]
|
|
|
|
[tool.ruff.lint.isort.sections]
|
|
'__python__' = ['__python__']
|
|
|
|
[tool.pylsp-mypy]
|
|
enabled = false
|