-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove setup.cfg, switch to pyproject.toml, switch from FLake8 to Ruff
- Loading branch information
Showing
16 changed files
with
123 additions
and
86 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
.PHONY: test | ||
|
||
PYTHON_PKG=qgis_plugin_manager | ||
TESTDIR=test | ||
|
||
test: | ||
cd test && python3 -m unittest | ||
|
||
lint: | ||
@ruff check $(PYTHON_PKG) $(TESTDIR) | ||
|
||
lint-preview: | ||
@ruff check --preview $(PYTHON_PKG) $(TESTDIR) | ||
|
||
lint-fix: | ||
@ruff check --fix --preview $(PYTHON_PKG) $(TESTDIR) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
[tool.setuptools] | ||
license-files = "LICENSE" | ||
|
||
# Ruff configuration | ||
# See https://doc.astral.sh/ruff/configuration | ||
|
||
[tool.ruff] | ||
line-length = 110 | ||
target-version = "py37" | ||
exclude = [ | ||
".venv", | ||
".local", | ||
] | ||
|
||
[tool.ruff.format] | ||
indent-style = "space" | ||
|
||
[tool.ruff.lint] | ||
extend-select = ["E", "F", "I", "ANN", "W", "T", "COM", "RUF"] | ||
ignore = [ | ||
"ANN101", | ||
"ANN102", | ||
"ANN204", | ||
"T201", | ||
] | ||
|
||
[tool.ruff.lint.per-file-ignores] | ||
"test/*" = [ | ||
"ANN201", | ||
] | ||
|
||
[tool.ruff.lint.isort] | ||
lines-between-types = 1 | ||
known-third-party = [ | ||
"qgis", | ||
] | ||
order-by-type = true | ||
|
||
[tool.ruff.lint.flake8-annotations] | ||
#ignore-fully-untyped = true | ||
suppress-none-returning = true | ||
#suppress-dummy-args = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -39,5 +39,5 @@ | |
[ | ||
int(num) if num.isdigit() else num | ||
for num in __version__.replace("-", ".", 1).split(".") | ||
] | ||
], | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.