Skip to content

Commit 5bb460d

Browse files
committed
Add pylint linter
1 parent acee548 commit 5bb460d

2 files changed

Lines changed: 18 additions & 5 deletions

File tree

Makefile

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,20 @@
11
# Directories
22
SRC_PATHS := project_name/ test/ # FIXME
33

4-
# Tasks
4+
# Targets
55
.PHONY: help
66
help:
77
@echo "Available targets:"
88
@echo " help : Show this help message"
99
@echo " format : Format code using Ruff format"
1010
@echo " check_format : Check code formatting with Ruff format"
1111
@echo " ruff : Run Ruff linter"
12+
@echo " pylint : Run Pylint linter"
1213
@echo " mypy : Run MyPy static type checker"
13-
@echo " lint : Run Ruff linter and Mypy for static code analysis"
14+
@echo " lint : Run linters (Ruff, Pylint and Mypy)"
1415
@echo " test : Run tests using pytest"
16+
@echo " checks : Check format, lint, and test"
1517
@echo " clean : Clean up caches and build artifacts"
16-
@echo " checks : Run format, lint, and test"
1718

1819
.PHONY: format
1920
format:
@@ -35,18 +36,23 @@ ruff:
3536
@echo "=====> Running Ruff..."
3637
@poetry run ruff check $(SRC_PATHS)
3738

39+
.PHONY: pylint
40+
pylint:
41+
@echo "=====> Running Pylint..."
42+
@poetry run pylint $(SRC_PATHS)
43+
3844
.PHONY: mypy
3945
mypy:
4046
@echo "=====> Running Mypy..."
4147
@poetry run mypy $(SRC_PATHS)
4248

4349
.PHONY: lint
44-
lint: ruff mypy
50+
lint: ruff pylint mypy
4551

4652
.PHONY: test
4753
test:
4854
@echo "=====> Running tests..."
49-
@poetry run pytest
55+
@poetry run pytest test/
5056

5157
.PHONY: clean
5258
clean:

pyproject.toml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ readme = "README.md"
77

88
[tool.poetry.dependencies]
99
python = "^3.10"
10+
pylint = "*"
1011

1112
[tool.poetry.group.test.dependencies]
1213
pytest = "*"
@@ -51,6 +52,12 @@ unfixable = []
5152
[tool.ruff.format]
5253
line-ending = "lf"
5354

55+
[tool.pylint.format]
56+
max-line-length = 100
57+
58+
[tool.pylint.basic]
59+
no-docstring-rgx = "^__|^test_"
60+
5461
[build-system]
5562
requires = ["poetry-core"]
5663
build-backend = "poetry.core.masonry.api"

0 commit comments

Comments
 (0)